Closed jdchandler closed 6 years ago
No root password, please read Docker manual and supply the user flag to docker exec
@jdchandler and others who find this issue, I had the same issue and ended up creating a separate docker file just to apply those settings. This allows me to use the otherwise working cptactionhank/atlassian-jira-software image. Not sure if there is a best approach but hopefully this will save someone some time. All commands come from the Alpine Linux Wiki Dockerfile
FROM cptactionhank/atlassian-jira-software:7.8.2
# execute these commands to update the time zone as root
USER root
RUN set -x \
&& apk update \
&& apk add tzdata \
&& cp /usr/share/zoneinfo/America/Detroit /etc/localtime \
&& echo "America/Detroit" > /etc/timezone
# Switch back to unprivileged daemon account used by base image
USER daemon:daemon
You can also ssh into your image using docker exec -it --user root jira-app bash
and apply the commands manually, but I dont think theyll persist.
Is there a way to change the time zone from UTC to anything else?
I tried sudo cp /usr/share/zoneinfo/America/Chicago /etc/localtime but get the following: cp: cannot create regular file ‘/etc/localtime’: Permission denied
I can't do "su - root" as i get this below: su: must be run from a terminal
I found a workaround for that but still don't know the password for root or su: Password: su: Authentication failure