Hi guys!
First of all I want to personally thank you for the great work you’ve done on the Roots projects. It is amazing!
Secondly I want to ensure that I’ve spend 3 days reading all the threads related to my problem but could not find any suitable fix for the latest Trellis version I am using.
My problem is that I cannot run a http staging version and a https production version on a DO Droplet.
What I have:
Staging
/staging/wordpress_sites.yml
wordpress_sites:
staging.leathergadgets.com:
site_hosts:
- staging.leathergadgets.com
...
branch: develop
/staging/vault.yml
vault_wordpress_sites:
staging.leathergadgets.com:
/hosts/staging
[staging]
188.166.149.109
[web]
188.166.149.109
Production
/staging/wordpress_sites.yml
wordpress_sites:
leathergadgets.com:
site_hosts:
- leathergadgets.com
...
branch: master
/staging/vault.yml
vault_wordpress_sites:
leathergadgets.com:
/hosts/production
[production]
188.166.149.109
[web]
188.166.149.109
I’ve run ansible-playbook server.yml -e env=staging
and created the env, DB, files. Everything works fine. But when I try to run ansible-playbook server.yml -e env=production'
I get this error:
fatal: [188.166.149.109]: FAILED! => {"changed": false, "failed": true, "module_stderr": "", "module_stdout": "sudo: a password is required\r\n", "msg": "MODULE FAILURE", "parsed": false}
My question, if you could please help, is there a way of doing this? I feel that I am pretty close but I’m missing something for making this run smoothly.
Apart from this, the second part of my problem is if I can setup http - staging and https - production (with http2). I know that the nginx host file is generated by Trellis. Is it a good way of altering what’s in that file? I could do it manually, change port, add certs and so on but not sure if this is the best way.
Many thanks