It's generally bad practice for Docker images to run as root. However, the official Bitbucket and Confluence Server images run as root.
Unfortunately, if you're using an enterprise container management platform (we're using OpenShift), containers that run as root aren't even allowed to start. This is for securtiy purposes. Most people aren't willing to turn off security features in a production environment in order to run a docker image.
Is there any plans to fix this in the near future?
The image is set to run on a high port, so there shouldn't be much issue in running this as a non-root (or daemon) user, right?
Are there any news regarding that issue? I'm in the process of deploying confluence and bitbucket on Openshift as well. Would be very helpful to have a docker image which doesn't run as root (nor as daemon), but as an arbitrary user.
Hi Michael,
this required some changes to the Dockerfile. I managed to run it as an arbitrary user, however with a few issues regarding timeouts. I will clean up and probably add a pull request tomorrow :)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Any update on this? I'm also interested in running this container as a non-root user.
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
recent changes made the situation even worse. This part in the entrypoint.py file:
def gen_cfg(tmpl, target, env, user='root', group='root', mode=0o644, overwrite=True):
makes it definitely impossible to run the image as a non-root user.
@Michael Rose any chances that this is getting reworked in the near future?
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Rhätische Bahn AG please vote on https://jira.atlassian.com/browse/BSERV-12531 to promote nonroot Docker image
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.