Skip to content

Commit

Permalink
Adding/Clean-up of comments
Browse files Browse the repository at this point in the history
  • Loading branch information
oybed committed Jan 6, 2018
1 parent 7bdc7d8 commit e541a86
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion images/prune-ocp-projects/include/prune-ocp-projects.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
#PROJECT_EXCLUDE_SYSTEM
#PROJECT_EXCLUDE_USER

# Also make sure to declare the TIMESTAMP_HOURS_AGO environment variable with the
# number of hours "old" a project has to be for deletion - i.e.: '-2hours', '-24hours', etc
#TIMESTAMP_HOURS_AGO='-12hours'

# Use an indexed array to keep track of existing projects
declare -A projects

Expand Down Expand Up @@ -36,7 +40,6 @@ fi
# than the set number of hours
for project in "${!projects[@]}";
do
# need variable for time
purgetime=`date -d "${TIMESTAMP_HOURS_AGO}" +%s`
temp=`oc get project ${project} -o=custom-columns=time:.metadata.creationTimestamp --no-headers`
projects[${project}]=`date -d "${temp}" +%s`
Expand Down

0 comments on commit e541a86

Please sign in to comment.