Replace the inline gaufre.js/nginx.conf ConfigMap approach with a purpose-built custom image (sunbeam/integration-service) that builds the lagaufre.js v2 widget from the suitenumerique/integration source and serves it via nginx. Changes: - Rewrite integration-deployment.yaml: custom image, v2 services.json format, only actually-deployed services (docs, meet, people) - Add people-frontend nginx sub_filter overlay to rewrite the hardcoded production integration URL baked into the Next.js bundle at build time - Register integration image in local overlay kustomization
90 lines
2.2 KiB
YAML
90 lines
2.2 KiB
YAML
# La Gaufre integration service — O Estúdio app launcher (La Gaufre v2).
|
|
# Serves the lagaufre.js v2 widget, SVG logos, and the v2 services API.
|
|
# Apps load gaufre.js (via people-frontend sub_filter) which in turn initialises
|
|
# the v2 widget with the button already rendered by @gouvfr-lasuite/ui-kit.
|
|
#
|
|
# Image: src.DOMAIN_SUFFIX/studio/integration:latest
|
|
# Built from sunbeam/integration-service/ (context: sunbeam/ root)
|
|
# Baked in: lagaufre.js v2, official La Suite logos, custom logos, gaufre.js, nginx.conf
|
|
#
|
|
# ConfigMap: only services.json (v2 format) — the one thing that varies per env
|
|
# DOMAIN_SUFFIX substituted at deploy time.
|
|
|
|
---
|
|
apiVersion: v1
|
|
kind: ConfigMap
|
|
metadata:
|
|
name: integration-config
|
|
namespace: lasuite
|
|
data:
|
|
services.json: |
|
|
{
|
|
"services": [
|
|
{
|
|
"name": "Documentos",
|
|
"url": "https://docs.DOMAIN_SUFFIX",
|
|
"logo": "https://integration.DOMAIN_SUFFIX/logos/docs.svg"
|
|
},
|
|
{
|
|
"name": "Reuniões",
|
|
"url": "https://meet.DOMAIN_SUFFIX",
|
|
"logo": "https://integration.DOMAIN_SUFFIX/logos/visio.svg"
|
|
},
|
|
{
|
|
"name": "Humans",
|
|
"url": "https://people.DOMAIN_SUFFIX",
|
|
"logo": "https://integration.DOMAIN_SUFFIX/logos/people.svg"
|
|
}
|
|
]
|
|
}
|
|
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: integration
|
|
namespace: lasuite
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
app: integration
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: integration
|
|
spec:
|
|
containers:
|
|
- name: integration
|
|
image: integration
|
|
ports:
|
|
- name: http
|
|
containerPort: 80
|
|
volumeMounts:
|
|
- name: config
|
|
mountPath: /etc/integration/services.json
|
|
subPath: services.json
|
|
resources:
|
|
limits:
|
|
memory: 32Mi
|
|
requests:
|
|
memory: 16Mi
|
|
cpu: 5m
|
|
volumes:
|
|
- name: config
|
|
configMap:
|
|
name: integration-config
|
|
---
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: integration
|
|
namespace: lasuite
|
|
spec:
|
|
selector:
|
|
app: integration
|
|
ports:
|
|
- name: http
|
|
port: 80
|
|
targetPort: 80
|