feat: add generated configuration files and Kubernetes overlays

- Add generated TypeScript configuration exports for all environments
- Create development and production Kubernetes overlay directories
- Include environment-specific kustomization configurations
- Add namespace and resource definitions for proper K8s deployment
- Enable environment-specific configuration management
This commit is contained in:
William Valentin
2025-09-08 09:45:27 -07:00
parent f3936f23fe
commit 78f5bbd90f
6 changed files with 492 additions and 0 deletions

View File

@@ -0,0 +1,43 @@
# Kubernetes configuration for development
# Generated automatically from unified configuration
# Generated on: 2025-09-08T16:32:25.389Z
APP_NAME=rxminder
APP_VERSION=1.0.0
NODE_ENV=development
APP_BASE_URL=rxminder.192.168.153.243.nip.io
PORT=5173
COUCHDB_URL=http://rxminder-couchdb-service:5984
COUCHDB_USER=admin
COUCHDB_PASSWORD=L7tfqHyg0T4sIYiWK
COUCHDB_DATABASE_NAME=meds_app
USE_MOCK_DB=false
KUBERNETES_NAMESPACE=rxminder-dev
INGRESS_HOST=rxminder.192.168.153.243.nip.io
INGRESS_CLASS=nginx
CERT_MANAGER_ISSUER=letsencrypt-prod
STORAGE_CLASS=longhorn
STORAGE_SIZE=1Gi
ENABLE_EMAIL_VERIFICATION=true
ENABLE_OAUTH=true
ENABLE_ADMIN_INTERFACE=true
ENABLE_MONITORING=false
ENABLE_METRICS=false
DEBUG_MODE=true
LOG_LEVEL=debug
LOG_FORMAT=text
CACHE_TTL=300
REQUEST_TIMEOUT=30000
MAX_CONNECTIONS=100
ENABLE_CORS=true
CORS_ORIGIN=*
FRONTEND_REPLICAS=1
DATABASE_REPLICAS=1
FRONTEND_MEMORY_REQUEST=128Mi
FRONTEND_CPU_REQUEST=50m
FRONTEND_MEMORY_LIMIT=256Mi
FRONTEND_CPU_LIMIT=200m
DATABASE_MEMORY_REQUEST=256Mi
DATABASE_CPU_REQUEST=100m
DATABASE_MEMORY_LIMIT=512Mi
DATABASE_CPU_LIMIT=500m

View File

@@ -0,0 +1,73 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
metadata:
name: rxminder-development
# Reference the base configuration
resources:
- ../../base
- namespace.yaml
# Override namespace for development
namespace: rxminder-dev
# Development-specific labels
labels:
- pairs:
environment: development
tier: development
# Development image tags and configurations
images:
- name: frontend-image
newName: gitea-http.taildb3494.ts.net/will/meds
newTag: latest
- name: couchdb-image
newName: couchdb
newTag: 3.3.2
# Development replicas
replicas:
- name: rxminder-frontend
count: 1
- name: rxminder-couchdb
count: 1
# Environment-specific patches
patches:
# Resource limits
- target:
kind: Deployment
name: rxminder-frontend
patch: |-
- op: replace
path: /spec/template/spec/containers/0/resources
value:
requests:
memory: "128Mi"
cpu: "50m"
limits:
memory: "256Mi"
cpu: "200m"
- target:
kind: StatefulSet
name: rxminder-couchdb
patch: |-
- op: replace
path: /spec/template/spec/containers/0/resources
value:
requests:
memory: "256Mi"
cpu: "100m"
limits:
memory: "512Mi"
cpu: "500m"
# ConfigMap generation
configMapGenerator:
- name: rxminder-config
envs:
- config.env
behavior: create