Add cycling deployments and updating config
Add kube config with refactor to kube accessor Add tests for k8s accessor, some styling changes
This commit is contained in:
parent
d387ba171f
commit
eea5fe3391
23 changed files with 830 additions and 560 deletions
|
@ -0,0 +1,14 @@
|
|||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
namespace: quay-enterprise
|
||||
name: quay-enterprise-config-tool
|
||||
spec:
|
||||
type: NodePort
|
||||
ports:
|
||||
- protocol: TCP
|
||||
port: 443
|
||||
targetPort: 443
|
||||
nodePort: 30090
|
||||
selector:
|
||||
quay-enterprise-component: config-tool
|
|
@ -0,0 +1,5 @@
|
|||
apiVersion: v1
|
||||
kind: ServiceAccount
|
||||
metadata:
|
||||
name: qe-config-tool-serviceaccount
|
||||
namespace: quay-enterprise
|
|
@ -0,0 +1,12 @@
|
|||
apiVersion: rbac.authorization.k8s.io/v1beta1
|
||||
kind: RoleBinding
|
||||
metadata:
|
||||
name: quay-enterprise-config-tool-writer
|
||||
namespace: quay-enterprise
|
||||
roleRef:
|
||||
apiGroup: rbac.authorization.k8s.io
|
||||
kind: Role
|
||||
name: quay-enterprise-config-tool-role
|
||||
subjects:
|
||||
- kind: ServiceAccount
|
||||
name: qe-config-tool-serviceaccount
|
|
@ -0,0 +1,29 @@
|
|||
apiVersion: rbac.authorization.k8s.io/v1beta1
|
||||
kind: Role
|
||||
metadata:
|
||||
name: quay-enterprise-config-tool-role
|
||||
namespace: quay-enterprise
|
||||
rules:
|
||||
- apiGroups:
|
||||
- ""
|
||||
resources:
|
||||
- secrets
|
||||
verbs:
|
||||
- get
|
||||
- put
|
||||
- patch
|
||||
- update
|
||||
- apiGroups:
|
||||
- ""
|
||||
resources:
|
||||
- namespaces
|
||||
verbs:
|
||||
- get
|
||||
- apiGroups:
|
||||
- "extensions"
|
||||
- "apps"
|
||||
resources:
|
||||
- deployments
|
||||
verbs:
|
||||
- list
|
||||
- patch
|
30
config_app/docs/k8s_templates/qe-config-tool.yml
Normal file
30
config_app/docs/k8s_templates/qe-config-tool.yml
Normal file
|
@ -0,0 +1,30 @@
|
|||
apiVersion: extensions/v1beta1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
namespace: quay-enterprise
|
||||
name: quay-enterprise-config-tool
|
||||
labels:
|
||||
quay-enterprise-component: config-tool
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
quay-enterprise-component: config-tool
|
||||
template:
|
||||
metadata:
|
||||
namespace: quay-enterprise
|
||||
labels:
|
||||
quay-enterprise-component: config-tool
|
||||
spec:
|
||||
serviceAccountName: qe-config-tool-serviceaccount
|
||||
volumes:
|
||||
- name: configvolume
|
||||
secret:
|
||||
secretName: quay-enterprise-config-secret
|
||||
containers:
|
||||
- name: quay-enterprise-config-tool
|
||||
image: config-app:latest # TODO: change to reference to quay image?
|
||||
imagePullPolicy: IfNotPresent # enable when testing with minikube
|
||||
args: ["config"]
|
||||
ports:
|
||||
- containerPort: 80
|
Reference in a new issue