diff options
Diffstat (limited to 'Dockerfile-template')
-rw-r--r-- | Dockerfile-template | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/Dockerfile-template b/Dockerfile-template index 8c2e084..54609ca 100644 --- a/Dockerfile-template +++ b/Dockerfile-template @@ -61,3 +61,12 @@ COPY blueprints/ /blueprints # Set up runtime script ENTRYPOINT exec "/scripts/bootstrap.sh" + +# Set up a non-root user +RUN mkdir -p /opt/bootstrap \ + && useradd -d /opt/bootstrap bootstrap \ + && chown -R bootstrap:bootstrap /opt/bootstrap \ + && chown -R bootstrap:bootstrap /scripts \ + && chown -R bootstrap:bootstrap /blueprints \ + && chown -R bootstrap:bootstrap /opt/consul +USER bootstrap |