feat(gitops): add frontend apps and argocd applications
This commit is contained in:
parent
ea0fae89d6
commit
8eec430997
20 changed files with 309 additions and 0 deletions
9
apps/nxtgauge-admin-frontend/base/configmap.yaml
Normal file
9
apps/nxtgauge-admin-frontend/base/configmap.yaml
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: nxtgauge-admin-frontend-config
|
||||
namespace: nxtgauge
|
||||
data:
|
||||
NODE_ENV: "production"
|
||||
PORT: "3000"
|
||||
NEXT_PUBLIC_API_URL: "https://api.nxtgauge.com/api"
|
||||
52
apps/nxtgauge-admin-frontend/base/deployment.yaml
Normal file
52
apps/nxtgauge-admin-frontend/base/deployment.yaml
Normal file
|
|
@ -0,0 +1,52 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: nxtgauge-admin-frontend
|
||||
namespace: nxtgauge
|
||||
labels:
|
||||
app: nxtgauge-admin-frontend
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: nxtgauge-admin-frontend
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: nxtgauge-admin-frontend
|
||||
spec:
|
||||
containers:
|
||||
- name: admin-frontend
|
||||
image: ghcr.io/traceworks2023/nxtgauge-nov-2025-frontend
|
||||
imagePullPolicy: Always
|
||||
ports:
|
||||
- containerPort: 3000
|
||||
name: http
|
||||
envFrom:
|
||||
- configMapRef:
|
||||
name: nxtgauge-admin-frontend-config
|
||||
- secretRef:
|
||||
name: nxtgauge-admin-frontend-secrets
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /
|
||||
port: 3000
|
||||
initialDelaySeconds: 10
|
||||
periodSeconds: 10
|
||||
timeoutSeconds: 3
|
||||
failureThreshold: 3
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /
|
||||
port: 3000
|
||||
initialDelaySeconds: 20
|
||||
periodSeconds: 20
|
||||
timeoutSeconds: 3
|
||||
failureThreshold: 3
|
||||
resources:
|
||||
requests:
|
||||
cpu: 100m
|
||||
memory: 128Mi
|
||||
limits:
|
||||
cpu: 500m
|
||||
memory: 512Mi
|
||||
18
apps/nxtgauge-admin-frontend/base/ingress.yaml
Normal file
18
apps/nxtgauge-admin-frontend/base/ingress.yaml
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
apiVersion: networking.k8s.io/v1
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: nxtgauge-admin-frontend
|
||||
namespace: nxtgauge
|
||||
spec:
|
||||
ingressClassName: traefik
|
||||
rules:
|
||||
- host: admin.nxtgauge.com
|
||||
http:
|
||||
paths:
|
||||
- path: /
|
||||
pathType: Prefix
|
||||
backend:
|
||||
service:
|
||||
name: nxtgauge-admin-frontend
|
||||
port:
|
||||
number: 80
|
||||
9
apps/nxtgauge-admin-frontend/base/kustomization.yaml
Normal file
9
apps/nxtgauge-admin-frontend/base/kustomization.yaml
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
resources:
|
||||
- namespace.yaml
|
||||
- configmap.yaml
|
||||
- secret.yaml
|
||||
- deployment.yaml
|
||||
- service.yaml
|
||||
- ingress.yaml
|
||||
4
apps/nxtgauge-admin-frontend/base/namespace.yaml
Normal file
4
apps/nxtgauge-admin-frontend/base/namespace.yaml
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
apiVersion: v1
|
||||
kind: Namespace
|
||||
metadata:
|
||||
name: nxtgauge
|
||||
14
apps/nxtgauge-admin-frontend/base/secret.yaml
Normal file
14
apps/nxtgauge-admin-frontend/base/secret.yaml
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: nxtgauge-admin-frontend-secrets
|
||||
namespace: nxtgauge
|
||||
type: Opaque
|
||||
stringData:
|
||||
MAIL_FROM: "REPLACE_ME"
|
||||
MAIL_SMTP_HOST: "REPLACE_ME"
|
||||
MAIL_SMTP_PORT: "587"
|
||||
MAIL_SMTP_SECURE: "false"
|
||||
MAIL_SMTP_STARTTLS: "true"
|
||||
MAIL_SMTP_USER: "REPLACE_ME"
|
||||
MAIL_SMTP_PASS: "REPLACE_ME"
|
||||
16
apps/nxtgauge-admin-frontend/base/service.yaml
Normal file
16
apps/nxtgauge-admin-frontend/base/service.yaml
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: nxtgauge-admin-frontend
|
||||
namespace: nxtgauge
|
||||
labels:
|
||||
app: nxtgauge-admin-frontend
|
||||
spec:
|
||||
type: ClusterIP
|
||||
selector:
|
||||
app: nxtgauge-admin-frontend
|
||||
ports:
|
||||
- name: http
|
||||
port: 80
|
||||
targetPort: 3000
|
||||
protocol: TCP
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
resources:
|
||||
- ../../base
|
||||
patchesStrategicMerge:
|
||||
- replicas-patch.yaml
|
||||
images:
|
||||
- name: ghcr.io/traceworks2023/nxtgauge-nov-2025-frontend
|
||||
newTag: testingcodex-latest
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: nxtgauge-admin-frontend
|
||||
namespace: nxtgauge
|
||||
spec:
|
||||
replicas: 1
|
||||
9
apps/nxtgauge-frontendwebsite/base/configmap.yaml
Normal file
9
apps/nxtgauge-frontendwebsite/base/configmap.yaml
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: nxtgauge-frontendwebsite-config
|
||||
namespace: nxtgauge
|
||||
data:
|
||||
NODE_ENV: "production"
|
||||
PORT: "3000"
|
||||
NEXT_PUBLIC_API_URL: "https://api.nxtgauge.com/api"
|
||||
52
apps/nxtgauge-frontendwebsite/base/deployment.yaml
Normal file
52
apps/nxtgauge-frontendwebsite/base/deployment.yaml
Normal file
|
|
@ -0,0 +1,52 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: nxtgauge-frontendwebsite
|
||||
namespace: nxtgauge
|
||||
labels:
|
||||
app: nxtgauge-frontendwebsite
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: nxtgauge-frontendwebsite
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: nxtgauge-frontendwebsite
|
||||
spec:
|
||||
containers:
|
||||
- name: frontendwebsite
|
||||
image: ghcr.io/traceworks2023/nxtgauge-frontendwebsite
|
||||
imagePullPolicy: Always
|
||||
ports:
|
||||
- containerPort: 3000
|
||||
name: http
|
||||
envFrom:
|
||||
- configMapRef:
|
||||
name: nxtgauge-frontendwebsite-config
|
||||
- secretRef:
|
||||
name: nxtgauge-frontendwebsite-secrets
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /
|
||||
port: 3000
|
||||
initialDelaySeconds: 10
|
||||
periodSeconds: 10
|
||||
timeoutSeconds: 3
|
||||
failureThreshold: 3
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /
|
||||
port: 3000
|
||||
initialDelaySeconds: 20
|
||||
periodSeconds: 20
|
||||
timeoutSeconds: 3
|
||||
failureThreshold: 3
|
||||
resources:
|
||||
requests:
|
||||
cpu: 100m
|
||||
memory: 128Mi
|
||||
limits:
|
||||
cpu: 500m
|
||||
memory: 512Mi
|
||||
18
apps/nxtgauge-frontendwebsite/base/ingress.yaml
Normal file
18
apps/nxtgauge-frontendwebsite/base/ingress.yaml
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
apiVersion: networking.k8s.io/v1
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: nxtgauge-frontendwebsite
|
||||
namespace: nxtgauge
|
||||
spec:
|
||||
ingressClassName: traefik
|
||||
rules:
|
||||
- host: test121.nxtgauge.com
|
||||
http:
|
||||
paths:
|
||||
- path: /
|
||||
pathType: Prefix
|
||||
backend:
|
||||
service:
|
||||
name: nxtgauge-frontendwebsite
|
||||
port:
|
||||
number: 80
|
||||
9
apps/nxtgauge-frontendwebsite/base/kustomization.yaml
Normal file
9
apps/nxtgauge-frontendwebsite/base/kustomization.yaml
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
resources:
|
||||
- namespace.yaml
|
||||
- configmap.yaml
|
||||
- secret.yaml
|
||||
- deployment.yaml
|
||||
- service.yaml
|
||||
- ingress.yaml
|
||||
4
apps/nxtgauge-frontendwebsite/base/namespace.yaml
Normal file
4
apps/nxtgauge-frontendwebsite/base/namespace.yaml
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
apiVersion: v1
|
||||
kind: Namespace
|
||||
metadata:
|
||||
name: nxtgauge
|
||||
7
apps/nxtgauge-frontendwebsite/base/secret.yaml
Normal file
7
apps/nxtgauge-frontendwebsite/base/secret.yaml
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: nxtgauge-frontendwebsite-secrets
|
||||
namespace: nxtgauge
|
||||
type: Opaque
|
||||
stringData: {}
|
||||
16
apps/nxtgauge-frontendwebsite/base/service.yaml
Normal file
16
apps/nxtgauge-frontendwebsite/base/service.yaml
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: nxtgauge-frontendwebsite
|
||||
namespace: nxtgauge
|
||||
labels:
|
||||
app: nxtgauge-frontendwebsite
|
||||
spec:
|
||||
type: ClusterIP
|
||||
selector:
|
||||
app: nxtgauge-frontendwebsite
|
||||
ports:
|
||||
- name: http
|
||||
port: 80
|
||||
targetPort: 3000
|
||||
protocol: TCP
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
resources:
|
||||
- ../../base
|
||||
patchesStrategicMerge:
|
||||
- replicas-patch.yaml
|
||||
images:
|
||||
- name: ghcr.io/traceworks2023/nxtgauge-frontendwebsite
|
||||
newTag: testingcodex-latest
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: nxtgauge-frontendwebsite
|
||||
namespace: nxtgauge
|
||||
spec:
|
||||
replicas: 1
|
||||
20
argocd/nxtgauge-admin-frontend-application.yaml
Normal file
20
argocd/nxtgauge-admin-frontend-application.yaml
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
apiVersion: argoproj.io/v1alpha1
|
||||
kind: Application
|
||||
metadata:
|
||||
name: nxtgauge-admin-frontend
|
||||
namespace: argocd
|
||||
spec:
|
||||
project: default
|
||||
source:
|
||||
repoURL: https://github.com/Traceworks2023/nxtgauge-gitops.git
|
||||
targetRevision: main
|
||||
path: apps/nxtgauge-admin-frontend/overlays/prod
|
||||
destination:
|
||||
server: https://kubernetes.default.svc
|
||||
namespace: nxtgauge
|
||||
syncPolicy:
|
||||
automated:
|
||||
prune: true
|
||||
selfHeal: true
|
||||
syncOptions:
|
||||
- CreateNamespace=true
|
||||
20
argocd/nxtgauge-frontendwebsite-application.yaml
Normal file
20
argocd/nxtgauge-frontendwebsite-application.yaml
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
apiVersion: argoproj.io/v1alpha1
|
||||
kind: Application
|
||||
metadata:
|
||||
name: nxtgauge-frontendwebsite
|
||||
namespace: argocd
|
||||
spec:
|
||||
project: default
|
||||
source:
|
||||
repoURL: https://github.com/Traceworks2023/nxtgauge-gitops.git
|
||||
targetRevision: main
|
||||
path: apps/nxtgauge-frontendwebsite/overlays/prod
|
||||
destination:
|
||||
server: https://kubernetes.default.svc
|
||||
namespace: nxtgauge
|
||||
syncPolicy:
|
||||
automated:
|
||||
prune: true
|
||||
selfHeal: true
|
||||
syncOptions:
|
||||
- CreateNamespace=true
|
||||
Loading…
Add table
Reference in a new issue