-
Notifications
You must be signed in to change notification settings - Fork 30
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
Domain + www subdomain - how to setup the symlinks? #34
Comments
Hi, Letsencrypt plugin have to do authorization and do challenge/response for each domain separately - but there is one problem: letsencrypt plugin is running only in context of one website (domain), ie. the one without www prefix, the second one (with www prefix) has different instance and don't know about challenge request and it doesn't know how to respond to it. Therefore there are two ideas mentioned earlier how to solve this problem. SymlinksLet's say you have your website placed in Create symlink to it:
so directory structure will looks like:
setup your webserver so both of your sites will be visible from the Internet, and than run letsencryt_plugin in Both challenges for newmarketscientific.com and www.newmarketscientific.com should be handled by newmarketscientific.com. Using the same letsencrypt DB in both websitesYou have two RoR applications: one in Use the same DB settings (config/database.yml) in both applications, so if you run letsencrypt plugin in Perhaps there is other/better way of doing this - I'm open for ideas. Hope it helps. |
I think you have misunderstood my problem. There are not two applications. The server is serving a single application, with DNS for both newmarketscientific.com and www.newmarketscientific.com pointing to the same IP address. This works fine under HTTP. The problem turned out to be the "server" line of the NGINX config. I added www.newmarketscientific.com to this, and it now works. There were no symlinks involved. Perhaps enhance the documentation to cover this situation? Thanks, Martin |
I am putting changes live to a site which includes this plugin (v0.0.7) for the first time.
There are instructions in the wiki to "create symlinks between sub-domains and main domain www directory", which I don't understand.
1. Expected behavior
The certificate covers both newmarketscientific.com and www.newmarketscientific.com.
2. Actual behavior
https://newmarketscientific.com works fine, but https://www.newmarketscientific.com does not:-
"The owner of www.newmarketscientific.com has configured their website improperly. To protect your information from being stolen, Firefox has not connected to this website.
www.newmarketscientific.com uses an invalid security certificate. The certificate is only valid for newmarketscientific.com"
3. Steps to reproduce issue
Put my code live (inc required empty folders, etc)
run openssl genrsa 4096 > key/keyfile.pem
run rake letsencrypt_plugin
...which runs fine.
However, I don't understand what I need to do re the following instruction in the wiki under "2a. Multiple domains":-
This is my nginx configuration:-
4. Your configuration (ruby, rails version, your Gemifile and Gemfile.lock files etc.)
Ruby 2.1.7 via rbenv
Rails 4.2.5
My gemfile:-
My gemfile.lock
Can you please help me understand what I need to do re the symlinks mentioned in the wiki.
Many thanks, Martin
The text was updated successfully, but these errors were encountered: