Skip to content

Comments

Feature/docker services run nonroot#117

Merged
ville-friman-siili merged 8 commits intodevelopfrom
feature/docker_services_run_nonroot
Oct 16, 2020
Merged

Feature/docker services run nonroot#117
ville-friman-siili merged 8 commits intodevelopfrom
feature/docker_services_run_nonroot

Conversation

@ville-friman-siili
Copy link
Contributor

@ville-friman-siili ville-friman-siili commented Oct 9, 2020

NOTICE I'll merge this branch myself into the development branch. This branch changes the port which the Ngnix listens so it requires changes elsewhere.

Renaming is part of commits making the dockerized services run
as a non-root user.
New nginx.conf contains configurations for the server instance.

This commit is a part of series of commits to make the dockerized services
run as a non-root.
This commit is a part of series of commits to make the dockerized services
run as a non-root user.
This commit is a part of series of commits to make the dockerized services
run as a non-root user.
…ver url

Nginx port and backend server url can be overridden whit build args
when building the Docker image. Arguments are nginx_port (default value
8080) and backend_url (default http://backend-server:5000).
For some reason container failed to start in OpenShift when log directory was under
/tmp due permission reasons so this moves them back to the orginal directory.
…file

Adds new section about the configurable Docker build arguments inside the
Dockerfile-prod.
@ville-friman-siili ville-friman-siili force-pushed the feature/docker_services_run_nonroot branch from 078bd30 to 057acd1 Compare October 13, 2020 05:55
CMD python server.py --database $DATABASE --host $HOST --user $USER --pw $PASSWORD --port $PORT

EXPOSE 5000 No newline at end of file
EXPOSE 5000
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the backend_url is configured with an env variable, should we also have a variable here to change the exposed port, if someone wants to expose something other than 5000? @ville-friman-siili

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent point. I was so focused on the frontend part that forgot this. I'll change this before merging.

vade5g
vade5g previously approved these changes Oct 14, 2020
Backend server's docker file was configured to expose always
the port 5000, which might not match with the $PORT argument given
to server.
@ville-friman-siili ville-friman-siili changed the base branch from master to develop October 14, 2020 11:06
@ville-friman-siili ville-friman-siili merged commit 694b6f8 into develop Oct 16, 2020
@ville-friman-siili ville-friman-siili deleted the feature/docker_services_run_nonroot branch October 16, 2020 08:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants