| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- apiVersion: apps/v1
- kind: DaemonSet
- metadata:
- name: netclient
- labels:
- app: netclient
- spec:
- selector:
- matchLabels:
- app: netclient
- template:
- metadata:
- labels:
- app: netclient
- spec:
- hostNetwork: true
- containers:
- - name: netclient
- image: gravitl/netclient:v0.5.11
- command: ['bash', '-c', "/root/netclient join -t $ACCESS_TOKEN --daemon off --name $(echo $NODE_NAME| sed -e s/.$NETWORK//); while true; do /root/netclient checkin --dns on -n $NETWORK; sleep $SLEEP; done"]
- env:
- - name: ACCESS_TOKEN
- value: "ACCESS_TOKEN_VALUE"
- - name: NETWORK
- value: "microk8s"
- - name: SLEEP
- value: "30"
- - name: NODE_NAME
- valueFrom:
- fieldRef:
- fieldPath: spec.nodeName
- volumeMounts:
- - mountPath: /etc/netclient
- name: etc-netclient
- - mountPath: /usr/bin/wg
- name: wg
- - mountPath: /var/run/dbus/system_bus_socket
- name: systemd-bus-socket
- securityContext:
- privileged: true
- volumes:
- - hostPath:
- path: /etc/netclient
- type: DirectoryOrCreate
- name: etc-netclient
- - hostPath:
- path: /usr/bin/wg
- type: File
- name: wg
- - hostPath:
- path: /usr/bin/resolvectl
- type: File
- name: resolvectl
- - hostPath:
- path: /var/run/dbus/system_bus_socket
- type: ""
- name: systemd-bus-socket
|