re-add drone
Some checks failed
Check Kubernetes YAMLs / scan (push) Failing after 24s

revert remove drone
This commit is contained in:
Lee
2024-09-23 23:59:54 +00:00
parent e6d3433ed1
commit 412a0cdc64
9 changed files with 234 additions and 0 deletions

View File

@ -0,0 +1,40 @@
kind: Role
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: drone
namespace: drone-ci
rules:
- apiGroups:
- ""
resources:
- secrets
verbs:
- create
- delete
- apiGroups:
- ""
resources:
- pods
- pods/log
verbs:
- get
- create
- delete
- list
- watch
- update
---
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: drone
namespace: drone-ci
subjects:
- kind: ServiceAccount
name: default
namespace: drone-ci
roleRef:
kind: Role
name: drone
apiGroup: rbac.authorization.k8s.io

View File

@ -0,0 +1,41 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: drone-runner
namespace: drone-ci
labels:
app.kubernetes.io/name: drone
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: drone
template:
metadata:
labels:
app.kubernetes.io/name: drone
spec:
containers:
- name: runner
image: drone/drone-runner-kube:latest
ports:
- containerPort: 3000
resources:
requests:
cpu: 50m
memory: 75Mi
limits:
cpu: 100m
memory: 200Mi
env:
- name: DRONE_RPC_HOST
value: drone.fascinated.cc
- name: DRONE_RPC_PROTO
value: https
- name: DRONE_NAMESPACE_DEFAULT
value: drone-ci
- name: DRONE_RPC_SECRET
valueFrom:
secretKeyRef:
name: drone-secret
key: DRONE_RPC_SECRET