You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
424 B

  1. ---
  2. - name: Setup nginx auth scaffolding dirs
  3. hosts: [ 'debian10' ]
  4. tasks:
  5. - shell: |-
  6. cd /etc/nginx
  7. mkdir -p auth.d passwords.d
  8. - copy:
  9. dest: '/etc/nginx/auth.d/grant-access-certbot.conf'
  10. content: |-
  11. set $auth_basic Restricted;
  12. if ($request_uri ~* "well-known") {
  13. set $auth_basic off;
  14. }
  15. auth_basic $auth_basic;