Skip to content

Commit

Permalink
Issue #33: Adding yaml lint config file to change line length to 120 …
Browse files Browse the repository at this point in the history
…and fixes violations
  • Loading branch information
SonOfLope committed Feb 7, 2024
1 parent 4c772aa commit eb4e521
Show file tree
Hide file tree
Showing 16 changed files with 465 additions and 463 deletions.
1 change: 1 addition & 0 deletions .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
name: Infrastructure integration workflow

on:

Check warning on line 4 in .github/workflows/workflow.yml

View workflow job for this annotation

GitHub Actions / yaml-check / yaml-lint-check

4:1 [truthy] truthy value should be one of [false, true]
Expand Down
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"editor.rulers": [80],
"editor.rulers": [120],
"files.trimTrailingWhitespace": true,
"files.trimFinalNewlines": true,
"files.insertFinalNewline": true
Expand Down
7 changes: 7 additions & 0 deletions .yamllint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
extends: default

rules:
line-length:
max: 120
allow-non-breakable-inline-mappings: true
32 changes: 16 additions & 16 deletions kubernetes/apps/finesse/finesse-backend-deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,22 +45,22 @@ spec:
spec:
serviceAccountName: secrets-reader
containers:
- name: finesse-backend
image: ghcr.io/ai-cfia/finesse-backend:main
imagePullPolicy: Always
command: ["/bin/sh", "-c"]
args:
- >
cp /vault/secrets/.env . &&
gunicorn --bind :8080 --workers 1 --threads 8 --timeout 0 --forwarded-allow-ips "*" app:app
ports:
- containerPort: 8080
livenessProbe:
httpGet:
path: /health
port: 8080
initialDelaySeconds: 60
periodSeconds: 10
- name: finesse-backend
image: ghcr.io/ai-cfia/finesse-backend:main
imagePullPolicy: Always
command: ["/bin/sh", "-c"]
args:
- >
cp /vault/secrets/.env . &&
gunicorn --bind :8080 --workers 1 --threads 8 --timeout 0 --forwarded-allow-ips "*" app:app
ports:
- containerPort: 8080
livenessProbe:
httpGet:
path: /health
port: 8080
initialDelaySeconds: 60
periodSeconds: 10

---
apiVersion: v1
Expand Down
22 changes: 11 additions & 11 deletions kubernetes/apps/finesse/finesse-frontend-deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,17 @@ spec:
spec:
serviceAccountName: secrets-reader
containers:
- name: finesse-frontend
image: ghcr.io/ai-cfia/finesse-frontend:main
imagePullPolicy: Always
ports:
- containerPort: 3000
livenessProbe:
httpGet:
path: /health
port: 3000
initialDelaySeconds: 60
periodSeconds: 10
- name: finesse-frontend
image: ghcr.io/ai-cfia/finesse-frontend:main
imagePullPolicy: Always
ports:
- containerPort: 3000
livenessProbe:
httpGet:
path: /health
port: 3000
initialDelaySeconds: 60
periodSeconds: 10

---
apiVersion: v1
Expand Down
54 changes: 27 additions & 27 deletions kubernetes/apps/finesse/finesse-ingress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,27 +6,27 @@ metadata:
namespace: finesse
annotations:
nginx.ingress.kubernetes.io/use-regex: "true"
nginx.ingress.kubernetes.io/rewrite-target: /$2 # https://kubernetes.github.io/ingress-nginx/examples/rewrite/
nginx.ingress.kubernetes.io/rewrite-target: /$2 # https://kubernetes.github.io/ingress-nginx/examples/rewrite/
cert-manager.io/cluster-issuer: letsencrypt-http
ingress.kubernetes.io/force-ssl-redirect: "true"
kubernetes.io/tls-acme: "true"
spec:
ingressClassName: nginx
tls:
- hosts:
- finesse.ninebasetwo.xyz
secretName: aciacfia-tls
- hosts:
- finesse.ninebasetwo.xyz
secretName: aciacfia-tls
rules:
- host: finesse.ninebasetwo.xyz
http:
paths:
- path: /api(/|$)(.*)
pathType: ImplementationSpecific
backend:
service:
name: finesse-backend-svc
port:
number: 8080
- host: finesse.ninebasetwo.xyz
http:
paths:
- path: /api(/|$)(.*)
pathType: ImplementationSpecific
backend:
service:
name: finesse-backend-svc
port:
number: 8080

---
# For more information check https://github.com/nginxinc/kubernetes-ingress/issues/323
Expand All @@ -44,17 +44,17 @@ metadata:
spec:
ingressClassName: nginx
tls:
- hosts:
- finesse.ninebasetwo.xyz
secretName: aciacfia-tls
- hosts:
- finesse.ninebasetwo.xyz
secretName: aciacfia-tls
rules:
- host: finesse.ninebasetwo.xyz
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: finesse-frontend-svc
port:
number: 3000
- host: finesse.ninebasetwo.xyz
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: finesse-frontend-svc
port:
number: 3000
30 changes: 15 additions & 15 deletions kubernetes/apps/nachet/nachet-backend-deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,21 +38,21 @@ spec:
spec:
serviceAccountName: secrets-reader
containers:
- name: nachet-backend
image: ghcr.io/ai-cfia/nachet-backend:48
imagePullPolicy: Always
command: ["/bin/sh", "-c"]
args:
- >
cp /vault/secrets/.env . && hypercorn -b :8080 app:app
ports:
- containerPort: 8080
livenessProbe:
httpGet:
path: /health
port: 8080
initialDelaySeconds: 60
periodSeconds: 10
- name: nachet-backend
image: ghcr.io/ai-cfia/nachet-backend:48
imagePullPolicy: Always
command: ["/bin/sh", "-c"]
args:
- >
cp /vault/secrets/.env . && hypercorn -b :8080 app:app
ports:
- containerPort: 8080
livenessProbe:
httpGet:
path: /health
port: 8080
initialDelaySeconds: 60
periodSeconds: 10

---
apiVersion: v1
Expand Down
25 changes: 13 additions & 12 deletions kubernetes/apps/nachet/nachet-frontend-deployment.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
apiVersion: apps/v1
kind: Deployment
metadata:
Expand All @@ -15,21 +16,21 @@ spec:
spec:
serviceAccountName: secrets-reader
containers:
- name: nachet-frontend
image: ghcr.io/ai-cfia/nachet-frontend:main
imagePullPolicy: Always
ports:
- containerPort: 3000
livenessProbe:
httpGet:
path: /
port: 3000
initialDelaySeconds: 60
periodSeconds: 10
- name: nachet-frontend
image: ghcr.io/ai-cfia/nachet-frontend:main
imagePullPolicy: Always
ports:
- containerPort: 3000
livenessProbe:
httpGet:
path: /
port: 3000
initialDelaySeconds: 60
periodSeconds: 10

---
apiVersion: v1
kind: Service
kind: Service
metadata:
name: nachet-frontend-svc
namespace: nachet
Expand Down
54 changes: 27 additions & 27 deletions kubernetes/apps/nachet/nachet-ingress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
namespace: nachet
annotations:
nginx.ingress.kubernetes.io/use-regex: "true"
nginx.ingress.kubernetes.io/rewrite-target: /$2 # https://kubernetes.github.io/ingress-nginx/examples/rewrite/
nginx.ingress.kubernetes.io/rewrite-target: /$2 # https://kubernetes.github.io/ingress-nginx/examples/rewrite/
nginx.ingress.kubernetes.io/proxy-body-size: "50m"
nginx.ingress.kubernetes.io/proxy-read-timeout: "120"
cert-manager.io/cluster-issuer: letsencrypt-http
Expand All @@ -15,20 +15,20 @@ metadata:
spec:
ingressClassName: nginx
tls:
- hosts:
- nachet.ninebasetwo.xyz
secretName: aciacfia-tls
- hosts:
- nachet.ninebasetwo.xyz
secretName: aciacfia-tls
rules:
- host: nachet.ninebasetwo.xyz
http:
paths:
- path: /api(/|$)(.*)
pathType: ImplementationSpecific
backend:
service:
name: nachet-backend-svc
port:
number: 8080
- host: nachet.ninebasetwo.xyz
http:
paths:
- path: /api(/|$)(.*)
pathType: ImplementationSpecific
backend:
service:
name: nachet-backend-svc
port:
number: 8080

---
# For more information check https://github.com/nginxinc/kubernetes-ingress/issues/323
Expand All @@ -47,17 +47,17 @@ metadata:
spec:
ingressClassName: nginx
tls:
- hosts:
- nachet.ninebasetwo.xyz
secretName: aciacfia-tls
- hosts:
- nachet.ninebasetwo.xyz
secretName: aciacfia-tls
rules:
- host: nachet.ninebasetwo.xyz
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: nachet-frontend-svc
port:
number: 3000
- host: nachet.ninebasetwo.xyz
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: nachet-frontend-svc
port:
number: 3000
Loading

0 comments on commit eb4e521

Please sign in to comment.