Move to new server
This commit is contained in:
38
k8s/deployment.yaml
Normal file
38
k8s/deployment.yaml
Normal file
@@ -0,0 +1,38 @@
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: swiss-backend
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: swiss-backend
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: swiss-backend
|
||||
spec:
|
||||
containers:
|
||||
- name: swiss-backend
|
||||
image: upquark/swiss-backend:latest
|
||||
imagePullPolicy: Always
|
||||
ports:
|
||||
- containerPort: 8080
|
||||
env:
|
||||
# - name: SPRING_PROFILES_ACTIVE
|
||||
# value: local
|
||||
- name: DB_URL
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
key: host
|
||||
name: pg-pguser-swiss-user
|
||||
- name: DB_USERNAME
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
key: user
|
||||
name: pg-pguser-swiss-user
|
||||
- name: DB_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
key: password
|
||||
name: pg-pguser-swiss-user
|
||||
27
k8s/external-postgres-service.yaml
Normal file
27
k8s/external-postgres-service.yaml
Normal file
@@ -0,0 +1,27 @@
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
annotations:
|
||||
kubectl.kubernetes.io/last-applied-configuration: |
|
||||
{"apiVersion":"v1","kind":"Service","metadata":{"annotations":{},"name":"external-postgres-svc","namespace":"swiss"},"spec":{"ports":[{"port":5432,"protocol":"TCP","targetPort":5432}]}}
|
||||
creationTimestamp: "2024-09-20T11:29:41Z"
|
||||
name: external-postgres-svc
|
||||
namespace: swiss
|
||||
resourceVersion: "82759"
|
||||
uid: d6fbb75a-9526-4524-a044-df93c0682fd8
|
||||
spec:
|
||||
clusterIP: 10.43.15.101
|
||||
clusterIPs:
|
||||
- 10.43.15.101
|
||||
internalTrafficPolicy: Cluster
|
||||
ipFamilies:
|
||||
- IPv4
|
||||
ipFamilyPolicy: SingleStack
|
||||
ports:
|
||||
- port: 5432
|
||||
protocol: TCP
|
||||
targetPort: 5432
|
||||
sessionAffinity: None
|
||||
type: ClusterIP
|
||||
status:
|
||||
loadBalancer: {}
|
||||
26
k8s/renovate-cronjob.yaml
Normal file
26
k8s/renovate-cronjob.yaml
Normal file
@@ -0,0 +1,26 @@
|
||||
apiVersion: batch/v1
|
||||
kind: CronJob
|
||||
metadata:
|
||||
name: renovate
|
||||
spec:
|
||||
schedule: '@hourly'
|
||||
concurrencyPolicy: Forbid
|
||||
jobTemplate:
|
||||
spec:
|
||||
template:
|
||||
spec:
|
||||
containers:
|
||||
- name: renovate
|
||||
# Update this to the latest available and then enable Renovate on
|
||||
# the manifest
|
||||
image: renovate/renovate:38.80.0
|
||||
args:
|
||||
- user/repo
|
||||
# Environment Variables
|
||||
env:
|
||||
- name: LOG_LEVEL
|
||||
value: debug
|
||||
envFrom:
|
||||
- secretRef:
|
||||
name: renovate-env
|
||||
restartPolicy: Never
|
||||
13
k8s/renovate-secret.yaml
Normal file
13
k8s/renovate-secret.yaml
Normal file
@@ -0,0 +1,13 @@
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: renovate-env
|
||||
type: Opaque
|
||||
stringData:
|
||||
# GITHUB_COM_TOKEN: 'any-personal-user-token-for-github-com-for-fetching-changelogs'
|
||||
# You can set RENOVATE_AUTODISCOVER to true to run Renovate on all repos you have push access to
|
||||
RENOVATE_AUTODISCOVER: 'false'
|
||||
RENOVATE_ENDPOINT: 'https://git.tenvoorde.org/api/v1'
|
||||
RENOVATE_GIT_AUTHOR: 'Renovate Bot <michel@tenvoorde.org>'
|
||||
RENOVATE_PLATFORM: 'gitea'
|
||||
RENOVATE_TOKEN: 'b9791f9de22856120ba85dd0adeb76178e5cb85f'
|
||||
12
k8s/service.yaml
Normal file
12
k8s/service.yaml
Normal file
@@ -0,0 +1,12 @@
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: swiss-backend
|
||||
spec:
|
||||
type: NodePort
|
||||
selector:
|
||||
app: swiss-backend
|
||||
ports:
|
||||
- protocol: TCP
|
||||
port: 8080
|
||||
nodePort: 30080
|
||||
Reference in New Issue
Block a user