-
Notifications
You must be signed in to change notification settings - Fork 80
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
Manage SSL Certificates with Let's Encrypt #17
Comments
Hi again @vialcollet 👋 Awesome, this is good to hear - this is something I've been wanting to implement for a while. Due to the flexibility of the role, and the different services it deploys, it cannot depend on other roles. I'd like to take the same approach with Let's Encrypt, being that I would implement my own code for the deployment, and expose a variable that allows user's to stick with my deployment code, or use another role. Considering you've been kind enough to share this with me - I'd like to ask you, as a user, what your thoughts would be on the above? This is really the approach I'd like to take, but I'll value any insight you may have on the matter :) |
Hi @cmacrae I really like your approach. I know there is a lot of debate around whether ansible roles should be highly specialized on a service or cover a full solution. In the case of Let's Encrypt you might also want to setup a cron job for the renewal. - name: Configure jitsi-meet server.
hosts: jitsi_servers
vars:
# Change this to match the DNS entry for your host IP.
jitsi_meet_server_name: '{{ ansible_fqdn }}'
roles:
- role: letsencrypt
become: yes
letsencrypt_email: "[email protected]"
letsencrypt_cert_domains:
- "{{ jitsi_meet_server_name }}"
tags: letsencrypt
- role: freedomofpress.jitsi-meet
jitsi_meet_ssl_cert_path: "/etc/letsencrypt/live/{{ jitsi_meet_server_name }}/fullchain.pem"
jitsi_meet_ssl_key_path: "/etc/letsencrypt/live/{{ jitsi_meet_server_name }}/privkey.pem"
become: yes
tags: jitsi What do you think? |
Hey @vialcollet - thanks so much for your response. That's great to hear about your explorations into my Sensu role. I definitely agree this is a good approach. I've got a very busy schedule at the moment, but I'm hoping I may get some time to implement this either this week, or the next - so just hang in there 👍 |
This was always a "Rocket.Chat in a box" as far as I'm concerned, so I don't see any issues with implementing here. I think I'll work on this soon |
Anyone want to give https://github.com/RocketChat/Rocket.Chat.Ansible/tree/letsencrypt a shot? |
Hi there. |
Yep. It was completed some time ago on this branch: https://github.com/RocketChat/Rocket.Chat.Ansible/tree/travis_build_test_WIP I use this branch on my personal server. It's been a while since I updated it though, life happened in the meantime as it always does and I forgot about where I left this. Thanks for reminding me - I'll put merging this to master and updating the documentation on my to-do list. |
@xenithorb thank you for adding lestencrypt. I'm looking forward to when it gets added to master. I use ansible heavily and have been debating between rocketchat or mattermost. So far I'm liking rocketchat. |
this worked for me so I say its good to go. |
My hold up on releasing this to master is the documentation. The README is a bit much on this one |: (My other hold-up was disappearing for several months, back now though!) |
no problem. I can try to help with the README. Is there any specific way you need it? |
Bit of stuff to go over... If you want to submit some PRs to change the README to reflect the new variable names and such that would be great. I'm terrible at documentation. I still plan on breaking apart: By rebasing. But I shouldn't change the code too much...., but those commits need to be documented better and clarified. Most of that I plan on doing myself, but the README.md tables are tedious |
Closing this since the working implementation is on develop |
@jlozadad please join me here: #51 |
- Add rocket_chat_letsencrypt_* variables to defaults/main.yml - Add tasks/letsencrypt.yml utilizing acme-tiny.py for SSL certs - Inserts cronjob in /etc/cron.monthly/acme-tiny_renew.sh to keep things current (perhaps systemd timer in the future)\ - Set newly generated generic RSA certs to 4096 bits - Add .well-known path for ACME in templates/rocket_chat.conf - Add `cron` to dependencies Resolves: #17
- Add rocket_chat_letsencrypt_* variables to defaults/main.yml - Add tasks/letsencrypt.yml utilizing acme-tiny.py for SSL certs - Inserts cronjob in /etc/cron.monthly/acme-tiny_renew.sh to keep things current (perhaps systemd timer in the future)\ - Set newly generated generic RSA certs to 4096 bits - Add .well-known path for ACME in templates/rocket_chat.conf - Add `cron` to dependencies Resolves: #17
- Add rocket_chat_letsencrypt_* variables to defaults/main.yml - Add tasks/letsencrypt.yml utilizing acme-tiny.py for SSL certs - Inserts cronjob in /etc/cron.monthly/acme-tiny_renew.sh to keep things current (perhaps systemd timer in the future)\ - Set newly generated generic RSA certs to 4096 bits - Add .well-known path for ACME in templates/rocket_chat.conf - Add `cron` to dependencies Resolves: #17
Hi and thanks a lot for this great role.
I have manage to handle let's encrypt. I am a beginner with Ansible so let me know what you think of the approach and I can submit a pull request if you want.
The main issue is that we need a valid nginx configuration (with valid certificates) in order to use the webroot validation.
My approach is the following (we should add a variable to activate this):
Changes in rocket_chat.conf.j2 (in the ssl server section):
Then my playbook:
The text was updated successfully, but these errors were encountered: