feat(portfolio): add staging environment
This commit is contained in:
parent
0dda9f282d
commit
13ea8de355
11 changed files with 339 additions and 0 deletions
22
apps/portfolio/base/deployment.yaml
Normal file
22
apps/portfolio/base/deployment.yaml
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: portfolio
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: portfolio
|
||||
template:
|
||||
metadata:
|
||||
annotations:
|
||||
labels:
|
||||
app: portfolio
|
||||
spec:
|
||||
containers:
|
||||
- image: registry.int.nc.landry.land/portfolio-site
|
||||
name: portfolio-site
|
||||
ports:
|
||||
- containerPort: 8080
|
||||
name: http
|
||||
restartPolicy: Always
|
||||
6
apps/portfolio/base/kustomization.yaml
Normal file
6
apps/portfolio/base/kustomization.yaml
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- ./deployment.yaml
|
||||
- ./service.yaml
|
||||
13
apps/portfolio/base/service.yaml
Normal file
13
apps/portfolio/base/service.yaml
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
annotations:
|
||||
labels:
|
||||
name: syncthing
|
||||
spec:
|
||||
ports:
|
||||
- name: http
|
||||
port: 80
|
||||
targetPort: http
|
||||
selector:
|
||||
app: syncthing
|
||||
11
apps/portfolio/overlays/prod-sites/config.json.disabled
Normal file
11
apps/portfolio/overlays/prod-sites/config.json.disabled
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
{
|
||||
"appName": "portfolio",
|
||||
"userGivenName": "portfolio",
|
||||
"destNamespace": "staging-sites",
|
||||
"destServer": "https://kubernetes.default.svc",
|
||||
"srcPath": "apps/portfolio/overlays/staging-sites",
|
||||
"srcRepoURL": "ssh://git@gitea-ssh.gitops.svc.cluster.local:2222/davad/argo.git",
|
||||
"srcTargetRevision": "",
|
||||
"labels": null,
|
||||
"annotations": null
|
||||
}
|
||||
31
apps/portfolio/overlays/prod-sites/ingress.yaml
Normal file
31
apps/portfolio/overlays/prod-sites/ingress.yaml
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
apiVersion: networking.k8s.io/v1
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: portfolio
|
||||
labels:
|
||||
app.kubernetes.io/name: portfolio
|
||||
annotations:
|
||||
cert-manager.io/cluster-issuer: letsencrypt-issuer
|
||||
nginx.ingress.kubernetes.io/whitelist-source-range: 192.168.1.1/16
|
||||
|
||||
gethomepage.dev/enabled: "true"
|
||||
gethomepage.dev/name: Portfolio
|
||||
gethomepage.dev/group: Sites
|
||||
gethomepage.dev/href: https://portfolio-test.int.nc.landry.land
|
||||
# gethomepage.dev/description:
|
||||
# gethomepage.dev/icon: syncthing
|
||||
spec:
|
||||
tls:
|
||||
- hosts:
|
||||
- "portfolio-test.int.nc.landry.land"
|
||||
rules:
|
||||
- host: "portfolio-test.int.nc.landry.land"
|
||||
http:
|
||||
paths:
|
||||
- path: "/"
|
||||
pathType: Prefix
|
||||
backend:
|
||||
service:
|
||||
name: portfolio
|
||||
port:
|
||||
name: http
|
||||
9
apps/portfolio/overlays/prod-sites/kustomization.yaml
Normal file
9
apps/portfolio/overlays/prod-sites/kustomization.yaml
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- ../../base
|
||||
- ./ingress.yaml
|
||||
images:
|
||||
- name: registry.int.nc.landry.land/portfolio-site
|
||||
newTag: latest
|
||||
11
apps/portfolio/overlays/staging-sites/config.json
Normal file
11
apps/portfolio/overlays/staging-sites/config.json
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
{
|
||||
"appName": "portfolio",
|
||||
"userGivenName": "portfolio",
|
||||
"destNamespace": "staging-sites",
|
||||
"destServer": "https://kubernetes.default.svc",
|
||||
"srcPath": "apps/portfolio/overlays/staging-sites",
|
||||
"srcRepoURL": "ssh://git@gitea-ssh.gitops.svc.cluster.local:2222/davad/argo.git",
|
||||
"srcTargetRevision": "",
|
||||
"labels": null,
|
||||
"annotations": null
|
||||
}
|
||||
31
apps/portfolio/overlays/staging-sites/ingress.yaml
Normal file
31
apps/portfolio/overlays/staging-sites/ingress.yaml
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
apiVersion: networking.k8s.io/v1
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: portfolio
|
||||
labels:
|
||||
app.kubernetes.io/name: portfolio
|
||||
annotations:
|
||||
cert-manager.io/cluster-issuer: letsencrypt-issuer
|
||||
nginx.ingress.kubernetes.io/whitelist-source-range: 192.168.1.1/16
|
||||
|
||||
gethomepage.dev/enabled: "true"
|
||||
gethomepage.dev/name: Portfolio
|
||||
gethomepage.dev/group: Sites
|
||||
gethomepage.dev/href: https://portfolio-test.int.nc.landry.land
|
||||
# gethomepage.dev/description:
|
||||
# gethomepage.dev/icon: syncthing
|
||||
spec:
|
||||
tls:
|
||||
- hosts:
|
||||
- "portfolio-test.int.nc.landry.land"
|
||||
rules:
|
||||
- host: "portfolio-test.int.nc.landry.land"
|
||||
http:
|
||||
paths:
|
||||
- path: "/"
|
||||
pathType: Prefix
|
||||
backend:
|
||||
service:
|
||||
name: portfolio
|
||||
port:
|
||||
name: http
|
||||
9
apps/portfolio/overlays/staging-sites/kustomization.yaml
Normal file
9
apps/portfolio/overlays/staging-sites/kustomization.yaml
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- ../../base
|
||||
- ./ingress.yaml
|
||||
images:
|
||||
- name: registry.int.nc.landry.land/portfolio-site
|
||||
newTag: staging
|
||||
Loading…
Add table
Add a link
Reference in a new issue