-
Notifications
You must be signed in to change notification settings - Fork 0
/
user-data.weavemaster.vmware
118 lines (110 loc) · 3.18 KB
/
user-data.weavemaster.vmware
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
#cloud-config
---
coreos:
etcd:
discovery: https://discovery.etcd.io/244c3e45b47518341081d11684798c5d
addr: $private_ipv4:4001
peer-addr: $private_ipv4:7001
fleet:
public-ip: $private_ipv4
units:
- name: etcd.service
command: start
- name: fleet.service
command: start
- name: docker-tcp.socket
command: start
enable: true
content: |
[Unit]
Description=Docker Socket for the API
[Socket]
ListenStream=2375
Service=docker.service
BindIPv6Only=both
[Install]
WantedBy=sockets.target
- name: 10-weave.network
runtime: false
content: |
[Match]
Type=bridge
Name=weave*
[Network]
- name: install-weave-clan-mgmt.service
command: start
enable: true
content: |
[Unit]
After=weave.service
After=network-online.target
After=docker.service
After=etcd.service
Description=Install weave-clan-mgmt
Documentation=https://github.com/gonkulator/weave-clanmgmt
Requires=network-online.target
Requires=docker.service
Requires=etcd.service
Requires=weave.service
[Service]
Type=oneshot
RemainAfterExit=yes
ExecStartPre=/bin/echo Pulling weave-clanmgmt from github...
ExecStartPre=/usr/bin/git clone https://github.com/gonkulator/weave-clanmgmt /home/core/weave-clanmgmt
ExecStartPre=/bin/echo Seeding clan data...
ExecStartPre=/home/core/weave-clanmgmt/seedclandata.sh
ExecStart=/bin/echo weave-clan-mgmt Installed
- name: join-weaveclans.service
command: start
enable: true
content: |
[Unit]
After=install-weave-clan-mgmt.service
After=weave.service
Requires=network-online.target
Requires=docker.service
Requires=weave.service
[Service]
ExecStart=/home/core/weave-clanmgmt/weave-clanmgmt attach dev
- name: install-weave.service
command: start
enable: true
content: |
[Unit]
After=network-online.target
After=docker.service
After=etcd.service
Description=Install Weave
Documentation=http://zettio.gihub.io/weave
Requires=network-online.target
Requires=docker.service
[Service]
Type=oneshot
RemainsAfterExit=yes
ExecStartPre=/usr/bin/wget -N -P /opt/bin https://raw.github.com/zettio/weave/master/weave
ExecStartPre=/usr/bin/chmod +x /opt/bin/weave
ExecStartPre=/usr/bin/docker pull zettio/weave:latest
ExecStart=/bin/echo Weave Installed
- name: weave.service
command: start
enable: true
content: |
[Unit]
After=install-weave.service
Description=Weave Network
Documentation=http://zettio.github.io/weave
Requires=install-weave.service
[Service]
EnvironmentFile=/etc/environment
ExecStartPre=/opt/bin/weave launch
ExecStartPre=/usr/bin/etcdctl mkdir /weave/servers
ExecStartPre=/usr/bin/etcdctl mk /weave/servers/master ${COREOS_PUBLIC_IPV4}
ExecStart=/usr/bin/docker logs -f weave
SuccessExitStatus=2
ExecStop=/opt/bin/weave stop
write_files:
- path: /etc/weave.env
permissions: 420
owner: root
content: |
WEAVE_LAUNCH_ARGS="IMAMASTER!"