mirror of
https://github.com/outbackdingo/matchbox.git
synced 2026-01-27 18:19:36 +00:00
* locksmithd should use etcd to lock for reboots * The default best-effort strategy uses the reboot strategy if etcd isn't running for some reason
33 lines
1.0 KiB
YAML
33 lines
1.0 KiB
YAML
---
|
|
systemd:
|
|
units:
|
|
- name: etcd2.service
|
|
enable: true
|
|
dropins:
|
|
- name: 40-etcd-cluster.conf
|
|
contents: |
|
|
[Service]
|
|
Environment="ETCD_NAME={{.etcd_name}}"
|
|
Environment="ETCD_ADVERTISE_CLIENT_URLS=http://{{.domain_name}}:2379"
|
|
Environment="ETCD_INITIAL_ADVERTISE_PEER_URLS=http://{{.domain_name}}:2380"
|
|
Environment="ETCD_LISTEN_CLIENT_URLS=http://0.0.0.0:2379"
|
|
Environment="ETCD_LISTEN_PEER_URLS=http://0.0.0.0:2380"
|
|
Environment="ETCD_INITIAL_CLUSTER={{.etcd_initial_cluster}}"
|
|
Environment="ETCD_STRICT_RECONFIG_CHECK=true"
|
|
- name: locksmithd.service
|
|
dropins:
|
|
- name: 40-etcd-lock.conf
|
|
contents: |
|
|
[Service]
|
|
Environment="REBOOT_STRATEGY=etcd-lock"
|
|
|
|
{{ if index . "ssh_authorized_keys" }}
|
|
passwd:
|
|
users:
|
|
- name: core
|
|
ssh_authorized_keys:
|
|
{{ range $element := .ssh_authorized_keys }}
|
|
- {{$element}}
|
|
{{end}}
|
|
{{end}}
|