This role installs certbot in a virtualenv with automated certificate renewal.
Running certbot as a non-root user and in a virtualenv provides extra security.
| # | |
| # Array merge takes a source array of objects and merges into into a | |
| # destination array of objects, while looking up an defined attribute from each | |
| # object (in both arrays) to de-duplicate the final array. | |
| # | |
| # So if you call with: | |
| # _ref: | |
| # path: path/to/array_merge.yaml | |
| # vars: | |
| # from: [ {"id": 1, name: "Alice"}, {"id": 2, name: "Bob"} ] |
| type ldapConnResult struct { | |
| Conn *ldap.Conn | |
| Error error | |
| } | |
| type userLdapPool struct { | |
| // maintain two "pool" connections managed through channels | |
| // one for read/write operations and another for authentication (re-binding) | |
| rwConn chan ldapConnResult | |
| rwConnReset chan bool |
| #!/usr/bin/perl -W | |
| open FILE_A, "<", $ARGV[0]; | |
| open FILE_B, "<", $ARGV[1]; | |
| my %a_lines = (); | |
| my %b_lines = (); | |
| my %a_only_lines = (); | |
| my %b_only_lines = (); | |
| my $both_lines = 0; |
| #!/usr/bin/python | |
| # | |
| # Eric Searcy | |
| # github.com/emsearcy | |
| """Ensure all mailing lists have DMARC mitigation enabled | |
| Set 'DEFAULT_DMARC_MODERATION_ACTION = 1' in mm_cfg.py to set policy for future | |
| changes. |
| // This is an independent work and is not sponsored or | |
| // affiliated with New Relic. | |
| // | |
| // Use of this source code is governed by the Apache 2.0 | |
| // license that can be found in the LICENSE file. | |
| package main | |
| import ( | |
| "fmt" |
| # Terraform Makefile | |
| # | |
| # Automates management of secrets from pass. | |
| # pass variable for DNS Made Easy | |
| #export TF_VAR_dme_skey := $(shell pass show services/dns/dme) | |
| .PHONY: error init plan apply clean | |
| error: |
| # Django script to export member lists from Mailman 3 to Groups.io | |
| # Includes a suffix "nomail", "digest", or "summary" as needed | |
| # | |
| # Sample command: | |
| # /opt/mailman3-web/virtualenv/bin/python ./manage.py runscript mm3_to_groupsio --script-args lists.example.com | |
| import codecs | |
| from django.conf import settings | |
| from django.core.management.base import BaseCommand, CommandError |
| diff --git a/includes/common.inc b/includes/common.inc | |
| index ceac115..f3ada95 100644 | |
| --- a/includes/common.inc | |
| +++ b/includes/common.inc | |
| @@ -2711,6 +2711,7 @@ function drupal_deliver_html_page($page_callback_result) { | |
| // Print a 503 page. | |
| drupal_maintenance_theme(); | |
| drupal_add_http_header('Status', '503 Service unavailable'); | |
| + drupal_add_http_header('Cache-Control', 'no-cache, must-revalidate, post-check=0, pre-check=0'); | |
| drupal_set_title(t('Site under maintenance')); |