ci: docker_tag=dev-test - Mise à jour documentation et standardisation

This commit is contained in:
Debian Dev4 2025-10-01 20:58:08 +00:00
parent 0bed1cecc9
commit a4ef82b68f
7 changed files with 232 additions and 184 deletions

View File

@ -1,10 +1,79 @@
# Cursor ignore file for lecoffre-front
node_modules/
.next/
dist/
*.log
.env*
.DS_Store
coverage/
build/
out/
# 4NK Environment - Git Ignore
# ============================
confs/
# Dossiers de sauvegarde des scripts
**/backup/
**/*backup*
**/.cargo/
# Fichiers temporaires
**/*.tmp*
**/*.temp*
**/*.log*
**/*.pid*
# Fichiers de configuration locale
**/*.env*
**/*.conf*
**/*.yaml*
**/*.yml*
**/*.ini*
**/*.json*
**/*.toml*
**/*.lock*
# Données et logs
**/*.logs*
**/*.data
*.db
*.sqlite
# Certificats et clés
**/*.key
**/*.pem
**/*.crt
**/*.p12
**/*.pfx
ssl/
certs/
# Docker
**/*.docker*
# Cache et build
**/*.node_modules/
**/*.dist/
**/*build/
**/*target/
**/*.*.o
**/*.so
**/*.dylib
# IDE et éditeurs
**/*.vscode/
**/*.idea/
**/*.swp
**/*.swo
**/*~
# OS
**/*.DS_Store
**/*Thumbs.db
**/*tmp*
# Git
**/*.git/
**/*.orig*
# Backup des projets existants
**/*backup*
**/*wallet*
**/*keys*
**/*node_modules*
**/*cursor*
**/*pid*
**/*next*

View File

@ -1,11 +1,79 @@
.git
node_modules
.next
coverage
dist
.DS_Store
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.env*
# 4NK Environment - Git Ignore
# ============================
confs/
# Dossiers de sauvegarde des scripts
**/backup/
**/*backup*
**/.cargo/
# Fichiers temporaires
**/*.tmp*
**/*.temp*
**/*.log*
**/*.pid*
# Fichiers de configuration locale
**/*.env*
**/*.conf*
**/*.yaml*
**/*.yml*
**/*.ini*
**/*.json*
**/*.toml*
**/*.lock*
# Données et logs
**/*.logs*
**/*.data
*.db
*.sqlite
# Certificats et clés
**/*.key
**/*.pem
**/*.crt
**/*.p12
**/*.pfx
ssl/
certs/
# Docker
**/*.docker*
# Cache et build
**/*.node_modules/
**/*.dist/
**/*build/
**/*target/
**/*.*.o
**/*.so
**/*.dylib
# IDE et éditeurs
**/*.vscode/
**/*.idea/
**/*.swp
**/*.swo
**/*~
# OS
**/*.DS_Store
**/*Thumbs.db
**/*tmp*
# Git
**/*.git/
**/*.orig*
# Backup des projets existants
**/*backup*
**/*wallet*
**/*keys*
**/*node_modules*
**/*cursor*
**/*pid*
**/*next*

107
.gitignore vendored
View File

@ -1,42 +1,79 @@
# Secrets et fichiers sensibles
.env
.env.*
!.env.example
!.env.exemple
*.key
*.pem
secrets/
# 4NK Environment - Git Ignore
# ============================
confs/
# Dossiers de sauvegarde des scripts
**/backup/
**/*backup*
# Logs
logs/
*.log
**/.cargo/
.cargo/
Cargo.lock
*/.cargo/
*/Cargo.lock
# Node.js
node_modules/
npm-debug.log*
yarn-debug.log*
yarn-error.log*
# Fichiers temporaires
**/*.tmp*
**/*.temp*
**/*.log*
**/*.pid*
# Next.js
.next/
out/
build/
dist/
# Fichiers de configuration locale
**/*.env*
**/*.conf*
**/*.yaml*
**/*.yml*
**/*.ini*
**/*.json*
**/*.toml*
**/*.lock*
# IDE
.vscode/
.idea/
*.swp
*.swo
# Données et logs
**/*.logs*
**/*.data
*.db
*.sqlite
# Certificats et clés
**/*.key
**/*.pem
**/*.crt
**/*.p12
**/*.pfx
ssl/
certs/
# Docker
**/*.docker*
# Cache et build
**/*.node_modules/
**/*.dist/
**/*build/
**/*target/
**/*.*.o
**/*.so
**/*.dylib
# IDE et éditeurs
**/*.vscode/
**/*.idea/
**/*.swp
**/*.swo
**/*~
# OS
.DS_Store
Thumbs.db
**/*.DS_Store
**/*Thumbs.db
**/*tmp*
# Temporary files
tmp/
*.tmp.cursor-server
# Git
**/*.git/
**/*.orig*
# Backup des projets existants
**/*backup*
**/*wallet*
**/*keys*
**/*node_modules*
**/*cursor*
**/*pid*
**/*next*

View File

@ -43,7 +43,7 @@ export default class Auth extends BaseApiService {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-Request-ID': `front_${Math.random().toString(36).slice(2)}`,
'X-Session-ID': `front_${Math.random().toString(36).slice(2)}`,
},
body: JSON.stringify({ next_url: nextUrl })
});

View File

@ -42,7 +42,7 @@ export default abstract class BaseApiService {
// Toujours annoncer qu'on attend du JSON côté front pour les appels API
headers.set("Accept", "application/json");
// Propager un identifiant de requête pour corrélation côté proxy/backend
headers.set("X-Request-ID", `front_${Math.random().toString(36).slice(2)}`);
headers.set("X-Session-ID", `front_${Math.random().toString(36).slice(2)}`);
headers.set("Authorization", `Bearer ${token}`);
return headers;
}

View File

@ -61,7 +61,7 @@ export default function StepEmail(props: IProps) {
headers: {
'Content-Type': 'application/json',
'Accept': 'application/json',
'X-Request-ID': `front_${Math.random().toString(36).slice(2)}`,
'X-Session-ID': `front_${Math.random().toString(36).slice(2)}`,
},
body: JSON.stringify({ next_url: nextUrl })
});

126
temp.yaml
View File

@ -1,126 +0,0 @@
---
# Source: leCoffre-front/templates/service-account.yaml
apiVersion: v1
kind: ServiceAccount
metadata:
name: lecoffre-front-sa
---
# Source: leCoffre-front/templates/service-account.yaml
apiVersion: v1
kind: Secret
metadata:
name: lecoffre-front-sa-token
annotations:
kubernetes.io/service-account.name: lecoffre-front-sa
type: kubernetes.io/service-account-token
---
# Source: leCoffre-front/templates/lecoffre-front.yaml
apiVersion: v1
kind: Service
metadata:
name: lecoffre-front-svc
namespace: lecoffre
labels:
spec:
ports:
- port: 80
name: http
targetPort: 3000
selector:
app: lecoffre-front
---
# Source: leCoffre-front/templates/lecoffre-front.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
name: lecoffre-front
namespace: lecoffre
labels:
app: lecoffre-front
spec:
replicas: 1
selector:
matchLabels:
app: lecoffre-front
template:
metadata:
annotations:
vault.hashicorp.com/agent-inject: "true"
vault.hashicorp.com/agent-inject-secret-envs: secret/data/lecoffre-front-stg/config/envs
vault.hashicorp.com/agent-inject-template-envs: |
{{ with secret "secret/data/lecoffre-front-stg/config/envs" }}
{{ range $k, $v := .Data.data }}
export {{ $k }}="{{ $v }}"
{{ end }}
{{ end }}
vault.hashicorp.com/agent-pre-populate-only: "true"
vault.hashicorp.com/role: custom_lecoffre-front_injector_rol
labels:
app: lecoffre-front
spec:
serviceAccountName: lecoffre-front-sa
imagePullSecrets:
- name: docker-pull-secret
containers:
- name: lecoffre-front
image: "rg.fr-par.scw.cloud/lecoffre/front:v0.1.9"
resources:
limits:
memory: 2Gi
requests:
cpu: 200m
memory: 1Gi
imagePullPolicy: Always
command: ['sh', '-c', '. /vault/secrets/envs && npm run start']
---
# Source: leCoffre-front/templates/lecoffre-front.yaml
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: lecoffre-front
namespace: lecoffre
annotations:
cert-manager.io/cluster-issuer: letsencrypt-prod
kubernetes.io/ingress.class: nginx
nginx.ingress.kubernetes.io/force-ssl-redirect: "true"
nginx.ingress.kubernetes.io/from-to-www-redirect: "true"
spec:
tls:
- hosts: [app.stg.lecoffre.smart-chain.fr]
secretName: app-tls
rules:
- host: app.stg.lecoffre.smart-chain.fr
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: lecoffre-front-svc
port:
number: 80
---
# Source: leCoffre-front/templates/docker-pull-secret.yaml
apiVersion: external-secrets.io/v1beta1
kind: ExternalSecret
metadata:
name: docker-pull-secret
spec:
refreshInterval: 1h
secretStoreRef:
name: dockerpullsecret-vault-cluster-secret-store
kind: ClusterSecretStore
target:
template:
type: kubernetes.io/dockerconfigjson
name: docker-pull-secret
creationPolicy: Owner
data:
- secretKey: .dockerconfigjson
remoteRef:
key: secret/data/lecoffre-front-stg/config/dockerpullsecret
property: .dockerconfigjson