The ENTRYPOINT script (/usr/local/bin/docker-entrypoint.sh) is executed first. The CMD (/usr/bin/supervisord -n -c /etc/supervisord.conf) is passed as arguments to the ENTRYPOINT script. The ENTRYPOINT script can choose to execute the CMD or perform other tasks before running the CMD. for now, supervisord is used in its current form, that of a python based application this is ok for now but other options could be considered, such as replacing it with a [go binary port of supervisord](https://github.com/ochinchina/supervisord), using [s6-overlay](https://github.com/just-containers/s6-overlay), [dumb-init](https://github.com/Yelp/dumb-init) or similar process management tools designed for containers. In the dockerfile, a user directive is used to lower from default root to that of a user that is created - 'www' and which is, for now, given a shell by which it is possible to log into this container for debugging and maintenance. further on, this can be removed somehow - likely a case for k8s as there are patterns for this that are perhaps not so much for docker alone.