Files
open-cluster-management/deploy/spoke/deployment.yaml
Jian Qiu 983391ba01 Add leader election flag (#193)
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2022-01-17 22:16:05 -05:00

48 lines
1.2 KiB
YAML

kind: Deployment
apiVersion: apps/v1
metadata:
name: spoke-agent
labels:
app: spoke-agent
spec:
replicas: 1
selector:
matchLabels:
app: spoke-agent
template:
metadata:
labels:
app: spoke-agent
spec:
serviceAccountName: spoke-agent-sa
containers:
- name: spoke-agent
image: quay.io/open-cluster-management/registration:latest
imagePullPolicy: IfNotPresent
args:
- "/registration"
- "agent"
- "--cluster-name=cluster1"
- "--bootstrap-kubeconfig=/spoke/bootstrap/kubeconfig"
- "--disable-leader-election"
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
privileged: false
runAsNonRoot: true
volumeMounts:
- name: bootstrap-secret
mountPath: "/spoke/bootstrap"
readOnly: true
- name: hub-kubeconfig
mountPath: "/spoke/hub-kubeconfig"
volumes:
- name: bootstrap-secret
secret:
secretName: bootstrap-secret
- name: hub-kubeconfig
emptyDir:
medium: Memory