Skip to content

Commit 473a071

Browse files
committed
Log startup of each script
1 parent 36ab799 commit 473a071

File tree

3 files changed

+5
-0
lines changed

3 files changed

+5
-0
lines changed

packer/linux/conf/bin/bk-configure-docker.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ trap '[[ $? = 0 ]] && on_exit' EXIT
2525
# See https://alestic.com/2010/12/ec2-user-data-output/
2626
exec > >(tee -a /var/log/elastic-stack.log | logger -t user-data -s 2>/dev/console) 2>&1
2727

28+
echo "Starting ${BASH_SOURCE[0]}..."
2829

2930
echo Sourcing /usr/local/lib/bk-configure-docker.sh...
3031
echo This file is written by the scripts in packer/scripts.

packer/linux/conf/bin/bk-install-elastic-stack.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ trap '[[ $? = 0 ]] && on_exit' EXIT
4141
# See https://alestic.com/2010/12/ec2-user-data-output/
4242
exec > >(tee -a /var/log/elastic-stack.log | logger -t user-data -s 2>/dev/console) 2>&1
4343

44+
echo "Starting ${BASH_SOURCE[0]}..."
45+
4446
# This needs to happen first so that the error reporting works
4547
token=$(curl -X PUT -H "X-aws-ec2-metadata-token-ttl-seconds: 60" --fail --silent --show-error --location http://169.254.169.254/latest/api/token)
4648
INSTANCE_ID=$(curl -H "X-aws-ec2-metadata-token: $token" --fail --silent --show-error --location http://169.254.169.254/latest/meta-data/instance-id)

packer/linux/conf/bin/bk-mount-instance-storage.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ trap '[[ $? = 0 ]] && on_exit' EXIT
2222
# See https://alestic.com/2010/12/ec2-user-data-output/
2323
exec > >(tee -a /var/log/elastic-stack.log | logger -t user-data -s 2>/dev/console) 2>&1
2424

25+
echo "Starting ${BASH_SOURCE[0]}..."
26+
2527
# Mount instance storage if we can
2628
# https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/InstanceStorage.html
2729

0 commit comments

Comments
 (0)