diff --git a/etcd-arm/etc/default/etcd b/etcd-arm/etc/default/etcd new file mode 100644 index 0000000..abcd95b --- /dev/null +++ b/etcd-arm/etc/default/etcd @@ -0,0 +1,9 @@ +ETCD_NAME=pi2 +ETCD_DATA_DIR=/var/lib/etcd +ETCD_INITIAL_ADVERTISE_PEER_URLS=http://192.168.1.229:2380 +ETCD_LISTEN_PEER_URLS=http://192.168.1.229:2380 +ETCD_LISTEN_CLIENT_URLS=http://192.168.1.229:2379,http://127.0.0.1:2379 +ETCD_ADVERTISE_CLIENT_URLS=http://192.168.1.229:2379 +ETCD_INITIAL_CLUSTER_TOKEN=pi-cluster +ETCD_INITIAL_CLUSTER=pi0=http://192.168.1.228:2380,pi1=http://192.168.1.207:2380,pi2=http://192.168.1.229:2380 +ETCD_INITIAL_CLUSTER_STATE=new diff --git a/etcd-arm/etc/systemd/system/etcd.service b/etcd-arm/etc/systemd/system/etcd.service new file mode 100644 index 0000000..0d886e1 --- /dev/null +++ b/etcd-arm/etc/systemd/system/etcd.service @@ -0,0 +1,11 @@ +[Unit] +Description=Etcd Daemon +After=network.target + +[Service] +EnvironmentFile=/etc/default/etcd +ExecStartPre=/usr/bin/mkdir -p $ETCD_DATA_DIR +ExecStart=/usr/local/bin/etcd + +[Install] +WantedBy=multi-user.target