[go: nahoru, domu]

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make finding images work in docker dev and ptvsd setup #2056

Merged

Conversation

valentijnscholten
Copy link
Member

Partial fix for #2045, makes finding images work in docker development setup.

Making it work in release mode will have to wait until @devGregA has finalized the migration to AppVeyor.

@valentijnscholten valentijnscholten changed the title make finding images work in docker dev setup make finding images work in docker dev and ptvsd setup Mar 13, 2020
@@ -25,6 +25,9 @@ http {
location /static {
alias /usr/share/nginx/html/static;
}
location /media {
alias /usr/share/nginx/html/media;
}
Copy link
Contributor

Choose a reason for hiding this comment

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

This nginx.conf is used in many setups. So I don't think it is a good idea to add it here and only provide a solution for docker-compose.

Copy link
Member Author

Choose a reason for hiding this comment

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

I couldn't find any other place it is being used

Copy link
Contributor

Choose a reason for hiding this comment

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

@alles-klar are you thinking of kubernetes? i don't have a strong opinion on this, but if the images are already not working, this is a start... :)

Copy link
Contributor

Choose a reason for hiding this comment

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

Sorry for the long delay. I think all setups are using the nginx config - also the productive ones. If we add the /media path there, all data that is stored there is free accessible without any authentication. If user add confidential pictures this is a security issue.

Copy link
Member Author

Choose a reason for hiding this comment

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

the production docker-compose setup is a container purely meant for defect dojo. if somebody would put sensitive data in there I don't think they know what they are doing :-). Also the production (release) config doesn't map any local files to the nginx media folders. setup.bash doesn't use this nginx.conf.

Copy link
Contributor

Choose a reason for hiding this comment

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

Using this setup just for debugging and development is fine but I am afraid that someone adopt this solution for other setups. Maybe we add a comment in the nginx config that it is currently for development only with docker-compose only and that this directory has to be empty in production?

@valentijnscholten valentijnscholten added this to the 1.7.0 milestone Apr 18, 2020
@valentijnscholten valentijnscholten merged commit 10da73b into DefectDojo:dev Jun 3, 2020
@valentijnscholten valentijnscholten deleted the dev-finding-images branch June 3, 2020 18:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants