Skip to content

Instantly share code, notes, and snippets.

@tjl2
Created May 16, 2013 11:15
Show Gist options
  • Save tjl2/5591015 to your computer and use it in GitHub Desktop.
Save tjl2/5591015 to your computer and use it in GitHub Desktop.
def create_at_job
# Creates an at job to call our vm.kickstart_destroyer_url in 5 minutes (gives the
# installation chance to use the KS file)
unless @verbose
output = ">> /dev/null 2>&1"
else
output = ''
end
at_file = "/tmp/ksd-#{@name}"
`echo "wget -q #{@vm.kickstart_destroyer_url}; rm #{at_file}" > #{at_file}`
`at -f #{at_file} now + 5 minutes #{output}`
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment