mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-09 18:45:54 +02:00
AWS: Add a timestamp to user-data.log
This way, multiple (failed) runs of the script won't overwrite the log file. Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
This commit is contained in:
@@ -107,7 +107,8 @@ import_aws_configuration() {
|
||||
chmod 700 /tmp/aws-user-data.script
|
||||
|
||||
# Run the user-data script
|
||||
/tmp/aws-user-data.script &>/var/log/user-data.log
|
||||
local now="$(date -u +"%s")"
|
||||
/tmp/aws-user-data.script &>/var/log/user-data.log.${now}
|
||||
|
||||
# Delete the script right away
|
||||
rm /tmp/aws-user-data.script
|
||||
|
||||
Reference in New Issue
Block a user