Skip to content

Commit

Permalink
Reverted logging changes
Browse files Browse the repository at this point in the history
  • Loading branch information
niallthomson committed Dec 22, 2023
1 parent e2ed27b commit ac52fb3
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions lab/scripts/installer.sh
Original file line number Diff line number Diff line change
Expand Up @@ -116,15 +116,7 @@ if [ ! -z "$REPOSITORY_REF" ]; then
cat << EOT > /usr/local/bin/reset-environment
#!/bin/bash
set -e
ts=\$(date +%s)
error=/eks-workshop/logs/action-\$ts.log
set -o pipefail
curl -fsSL https://raw.githubusercontent.com/${REPOSITORY_OWNER}/${REPOSITORY_NAME}/$REPOSITORY_REF/lab/bin/reset-environment | bash -s -- \$1 2>&1 | tee \$error
if [ \$? -ne 0 ]; then
echo "An error occurred, please contact your workshop proctor or raise an issue at https://github.com/aws-samples/eks-workshop-v2/issues"
echo "This is the log of that last action: \$error"
fi
set +o pipefail
curl -fsSL https://raw.githubusercontent.com/${REPOSITORY_OWNER}/${REPOSITORY_NAME}/$REPOSITORY_REF/lab/bin/reset-environment | bash -s -- \$1
EOT
chmod +x /usr/local/bin/reset-environment
cat << EOT > /usr/local/bin/delete-environment
Expand Down Expand Up @@ -171,6 +163,6 @@ EOT
chmod +x /usr/local/bin/delete-nodegroup
fi

mkdir -p /eks-workshop/logs
mkdir -p /eks-workshop

chown -R ec2-user /eks-workshop
chown ec2-user /eks-workshop

0 comments on commit ac52fb3

Please sign in to comment.