Docker Image improvements

Hi,

I have noticed your Docker image run several process inside (tomcat, postfix, …). I think, and I’m not alone, it’s a bad practice. (See docker - Why it is recommended to run only one process in a container? - DevOps Stack Exchange).

Could you improve that ?

Thanks.

The only process started in the images is the Tomcat server (I don’t remember why we install the “postfix” package but we don’t start a postfix process)

Thank you for your quick answer,

In your README file, you write :
'You can start a local Postfix SMTP server by using -e LOCAL_SMTP_SERVER=true"
this’s why the Postfix package is installed.

And in your run.sh file:
“if [ “$LOCAL_SMTP_SERVER” = “true” ]
then
echo “Starting SMTP server…”
postfix start
echo “…done”
fi”
This’s how Postfix is started.

So, if Postfix is never used, could use remove Postfix from the image?

Thanks.

I must admit I don’t remember this… I think this was implemented for a particular customer who needed this. I will check internally if it still makes sense.

Anyway I agree this should be isolated in a specialised image for this customer and removed from the default image.

Ok we have removed postfix from our default images so now there is only one possible process started in the container: Tomcat.

We have added some details in the readme file to explain what to do if you want to use this feature (with a disclaimer that says it is not a good idea to use it in production). See https://github.com/simplicitesoftware/docker/blob/master/README.md

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.