Skip to content
Snippets Groups Projects
Commit b0698090 authored by sgk's avatar sgk
Browse files

git subrepo pull (merge) float

subrepo:
  subdir:   "float"
  merged:   "89039534"
upstream:
  origin:   "https://git.autistici.org/ai3/float.git"
  branch:   "master"
  commit:   "89039534"
git-subrepo:
  version:  "0.4.7"
  origin:   "https://github.com/ingydotnet/git-subrepo"
  commit:   "c9ec2a6"
parent 3e3346f7
No related branches found
No related tags found
1 merge request!86#96 float subrepo upgrade
Pipeline #232414 passed
Showing
with 63 additions and 22 deletions
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
[subrepo] [subrepo]
remote = https://git.autistici.org/ai3/float.git remote = https://git.autistici.org/ai3/float.git
branch = master branch = master
commit = b02a3496b03886b59f9b1fd6c197d06c4a9ce66d commit = 89039534fb72c317de51d7a5c2f8e6815d61b982
parent = c6d787af527667d24631d61f7b3050d25cce8139 parent = 155d2691324dc97829db4e0a5f77b512bb8c0647
cmdver = 0.4.6 cmdver = 0.4.7
method = merge method = merge
...@@ -364,14 +364,13 @@ def command_create_env(path, services, passwords, playbooks, ...@@ -364,14 +364,13 @@ def command_create_env(path, services, passwords, playbooks,
# Catch ValueError to handle parsing errors for composite-valued # Catch ValueError to handle parsing errors for composite-valued
# options and print a friendly message. # options and print a friendly message.
try: try:
all_vars['inventory']['hosts'] = _random_hosts( extra_memberships = _parse_additional_host_groups(additional_host_groups)
num_hosts,
_parse_additional_host_groups(additional_host_groups),
)
except ValueError: except ValueError:
print('Unable to parse additional-host-group spec', file=sys.stderr) print('Unable to parse additional-host-group spec', file=sys.stderr)
return 1 return 1
all_vars['inventory']['hosts'] = _random_hosts(num_hosts, extra_memberships)
all_vars['ram'] = ram all_vars['ram'] = ram
all_vars['config']['domain_public'] = [domain] all_vars['config']['domain_public'] = [domain]
all_vars['config']['domain'] = ( all_vars['config']['domain'] = (
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
set -a set -a
. /etc/litestream/{{ dataset_tag }}.env . /etc/litestream/{{ dataset_tag }}.env
/usr/bin/litestream restore --config=/etc/litestream/{{ dataset_tag }}.yml --if-replica-exists -v "{{ dataset_path }}/{{ dataset_filename }}" /usr/bin/litestream restore --config=/etc/litestream/{{ dataset_tag }}.yml --if-replica-exists "{{ dataset_path }}/{{ dataset_filename }}"
if [ $? -gt 0 ]; then if [ $? -gt 0 ]; then
echo "ERROR: restore failed!" >&2 echo "ERROR: restore failed!" >&2
......
# Disable automatic conntrack helper assignment.
options nf_conntrack nf_conntrack_helper=0
# Obscure network protocols with a bad security track record. # Obscure network protocols with a bad security track record.
install dccp /bin/false install dccp /bin/false
install sctp /bin/false install sctp /bin/false
......
...@@ -38,6 +38,11 @@ ...@@ -38,6 +38,11 @@
dest: "/etc/sysctl.conf" dest: "/etc/sysctl.conf"
notify: reload sysctl notify: reload sysctl
- name: Configure kernel modules
template:
src: "modules.conf.j2"
dest: "/etc/modules-load.d/float-base.conf"
- name: Configure systemd - name: Configure systemd
copy: copy:
src: "system.conf" src: "system.conf"
......
# Make nf_conntrack sysctl available
nf_conntrack
...@@ -10,9 +10,9 @@ http: ...@@ -10,9 +10,9 @@ http:
enabled: true enabled: true
dns: dns:
enabled: true enabled: true
tsig_key_name: "acme" tsig_key_name: "acme."
tsig_key_algo: "{{ acme_tsig_key.algo }}" tsig_key_algo: "{{ acme_tsig_key.algo | lower }}."
tsig_key_secret: "{{ acme_tsig_key.private }}" tsig_key_secret: "{{ acme_tsig_key.public }}"
nameservers: nameservers:
{% for h in services['dns'].hosts | sort %} {% for h in services['dns'].hosts | sort %}
- {{ h }}.dns.{{ domain }} - {{ h }}.dns.{{ domain }}
......
# Script to convert each zone in a view to a series of in-view declarations
1i\
// Automatically generated, do not edit.
/^zone/{
a\
in-view "internal-in";\
};
p
}
...@@ -29,6 +29,11 @@ ...@@ -29,6 +29,11 @@
notify: reload bind notify: reload bind
register: dns_config register: dns_config
- name: Install in-view.sed script
copy:
src: "in-view.sed"
dest: "/etc/bind/in-view.sed"
- name: Create bind9 zone dirs - name: Create bind9 zone dirs
file: file:
path: "/etc/bind/zones" path: "/etc/bind/zones"
...@@ -60,6 +65,7 @@ ...@@ -60,6 +65,7 @@
changed_when: false changed_when: false
with_items: with_items:
- named.conf.zones - named.conf.zones
- named.conf.zones.in-view
- named.conf.internal-custom-zones - named.conf.internal-custom-zones
- named.conf.external-custom-zones - named.conf.external-custom-zones
...@@ -103,13 +109,17 @@ ...@@ -103,13 +109,17 @@
file: file:
path: "/etc/credentials/dnssec" path: "/etc/credentials/dnssec"
state: directory state: directory
mode: 0700 owner: root
group: bind
mode: 0750
- name: Install DNSSEC keys - name: Install DNSSEC keys
copy: copy:
src: "{{ item }}" src: "{{ item }}"
dest: "/etc/credentials/dnssec/{{ item | basename }}" dest: "/etc/credentials/dnssec/{{ item | basename }}"
mode: 0600 owner: root
group: bind
mode: 0640
with_fileglob: with_fileglob:
- "{{ credentials_dir }}/dnssec/K*.private" - "{{ credentials_dir }}/dnssec/K*.private"
- "{{ credentials_dir }}/dnssec/K*.key" - "{{ credentials_dir }}/dnssec/K*.key"
...@@ -32,6 +32,6 @@ view "external-in" in { ...@@ -32,6 +32,6 @@ view "external-in" in {
// Include manually-maintained zones. // Include manually-maintained zones.
include "/etc/bind/named.conf.external-custom-zones"; include "/etc/bind/named.conf.external-custom-zones";
// Include zonetool-maintained zones. // Include zonetool-maintained zones (in-view references).
include "/etc/bind/named.conf.zones"; include "/etc/bind/named.conf.zones.in-view";
}; };
...@@ -30,6 +30,9 @@ options { ...@@ -30,6 +30,9 @@ options {
dnssec-validation auto; dnssec-validation auto;
// For re-signing with dynamic updates.
key-directory "/etc/credentials/dnssec";
notify no; notify no;
rrset-order { order random; }; rrset-order { order random; };
......
...@@ -3,7 +3,11 @@ ...@@ -3,7 +3,11 @@
# Wrapper for zonetool, with the right options. # Wrapper for zonetool, with the right options.
# #
exec /usr/bin/zonetool \ set -e
rndc freeze
/usr/bin/zonetool \
--config /etc/dns/zonetool.yml \ --config /etc/dns/zonetool.yml \
--named-conf /etc/bind/named.conf.zones \ --named-conf /etc/bind/named.conf.zones \
--output-dir /etc/bind/zones --delete \ --output-dir /etc/bind/zones --delete \
...@@ -11,4 +15,12 @@ exec /usr/bin/zonetool \ ...@@ -11,4 +15,12 @@ exec /usr/bin/zonetool \
--ds-dir /etc/bind/dnssec-ds \ --ds-dir /etc/bind/dnssec-ds \
--nsec3-salt {{ dnssec_nsec3_salt }} \ --nsec3-salt {{ dnssec_nsec3_salt }} \
--dnssec-refresh \ --dnssec-refresh \
--update-policy 'grant acme zonesub TXT' \
/etc/dns/manual /etc/dns/auto /etc/dns/manual /etc/dns/auto
sed -n -f /etc/bind/in-view.sed \
/etc/bind/named.conf.zones \
> /etc/bind/named.conf.zones.in-view
rndc thaw
...@@ -7,6 +7,9 @@ status = error ...@@ -7,6 +7,9 @@ status = error
logger.action.name = org.elasticsearch.action logger.action.name = org.elasticsearch.action
logger.action.level = debug logger.action.level = debug
logger.deprecation.name = org.elasticsearch.deprecation
logger.deprecation.level = error
appender.rolling.type = RollingFile appender.rolling.type = RollingFile
appender.rolling.name = rolling appender.rolling.name = rolling
appender.rolling.fileName = ${sys:es.logs.base_path}${sys:file.separator}${sys:es.logs.cluster_name}.log appender.rolling.fileName = ${sys:es.logs.base_path}${sys:file.separator}${sys:es.logs.cluster_name}.log
......
...@@ -2,7 +2,7 @@ groups: ...@@ -2,7 +2,7 @@ groups:
- name: roles/float-infra-prometheus/templates/rules/rules_ssl_probes.conf - name: roles/float-infra-prometheus/templates/rules/rules_ssl_probes.conf
rules: rules:
- record: target:probe_ssl_cert_expiry:days - record: target:probe_ssl_cert_expiry:days
expr: ((min(probe_ssl_earliest_cert_expiry) by (probe,host)) - time()) / 86400 expr: ((min(probe_ssl_earliest_cert_expiry) by (float_job,probe,host)) - time()) / 86400
- record: service_credentials_expiration_time:days - record: service_credentials_expiration_time:days
expr: ((min(service_credentials_expiration_time) by (name,float_service)) - time()) / 86400 expr: ((min(service_credentials_expiration_time) by (name,float_service)) - time()) / 86400
......
...@@ -76,7 +76,7 @@ ...@@ -76,7 +76,7 @@
params: "{{ item.0.x509_params|default({}) }}" params: "{{ item.0.x509_params|default({}) }}"
private_key_path: "/etc/credentials/{{ item.0.credentials.ca_tag | default(default_ca_tag) }}/{{ item.0.credentials.name }}/{{ item.0.mode }}/private_key.pem" private_key_path: "/etc/credentials/{{ item.0.credentials.ca_tag | default(default_ca_tag) }}/{{ item.0.credentials.name }}/{{ item.0.mode }}/private_key.pem"
check: false check: false
when: "item.1.changed" when: "item.1.changed or (force_renew_credentials | default(False))"
loop: "{{ credentials | zip(x509_should_update.results) | list }}" loop: "{{ credentials | zip(x509_should_update.results) | list }}"
register: x509_csr register: x509_csr
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment