Skip to content

docker-compose.yml and nginx.conf updated - #53

Closed
javidovl wants to merge 2 commits into
BaseballCardTracker:mainfrom
javidovl:main
Closed

javidovl wants to merge 2 commits into
BaseballCardTracker:mainfrom
javidovl:main

Conversation

@javidovl

Copy link
Copy Markdown

First, notice in the nginx.conf the second server block is commented out. The reason is, in the case you run docker containers for the first time, it will not find the SSL certificate files because it is not generated yet. So, like this (commented out), you have to run containers and run the command sudo docker compose run --rm certbot certonly --webroot --webroot-path /var/www/certbot/ -d domain_name.com. After those files generated , those will be stored in the volume certbot. Without deleting this volume folder, cancel the comment part (second server block) and run containers. Then the website should redirect to https and it should work. Hope it helps!

This was referenced Apr 29, 2022
@codeguru42

codeguru42 commented Jun 9, 2022 •

Copy link
Copy Markdown
Member

Thanks for this PR. I saw this about a week ago and have been thikning about how to respond. If you are willing to iterate on this with me until I feel it is ready to merge, I'd be happy to discuss the direction to go with this. At a high level, I have a few comments/requests:

  1. This addresses 2 separate issues that I created. Please create a separate branch and PR for each one so that we can work on them separately. If there is a tight coupling between the two issues, then we can discuss how to proceed.
  2. I don't like committing commented out code to version control. I understand the reason for it here, but I don't think this should be the final solution. Let's discuss the approach further and figure out a way forward. For example, one possibility is to create a nginx.conf.sample file that a developer must copy and edit before building the docker images. I'm open to other ideas here, too, that don't require modifying a committed file. Whatever we decide, the instructions in the README file should describe the necessary steps to build a finished file. And the github action needs to be updated to follow those steps.

As I said, I'm open to discussing how to continue from here. Please post here what your thoughts are.

@codeguru42

codeguru42 commented Jul 8, 2022 •

Copy link
Copy Markdown
Member

@javidovl Thanks for your pull request. I will close it at this time since you have not responded to my comments. If you wish to reopen this pull request or submit a new one that addresses the comments, please feel free to do so.

@codeguru42 codeguru42 closed this Jul 8, 2022
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.

2 participants