Issue Summary
The shutdown-wait.sh script is placed in the repository and not found in the Bamboo agent pod.
From the Dockerfile configuration it looks like the script is not copied
This is reproducible on Data Center: (no)
Steps to Reproduce
- Deploy an agent using helm charts
- Check the running pod
Expected Results
The shutdown-wait.sh script should be in the base image to allow agent pods to shutdown gracefully according to below agent helm values
shutdown:
# -- The termination grace period for pods during shutdown. This
# should be set to the internal grace period, plus a small buffer
# to allow the JVM to fully terminate.
#
terminationGracePeriodSeconds: 30
# -- By default pods will be stopped via a [preStop hook](https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/),
# using a script supplied by the Docker image. If any other
# shutdown behaviour is needed it can be achieved by overriding
# this value. Note that the shutdown command needs to wait for the
# application shutdown completely before exiting; see [the default
# command](https://bitbucket.org/atlassian-docker/docker-bamboo-agent-base/src/master/shutdown-wait.sh)
# for details.
#
command: "/shutdown-wait.sh"
Actual Results
The script is not created and agents terminate without checking if the builds were completed
Workaround
Currently there is no known workaround for this behavior. A workaround will be added here when available