🔒 Add environment-based configuration system

- Add .env.example template with all configurable values
- Create comprehensive .gitignore for personal data
- Add sanitization script to remove hardcoded personal info
- Add environment-aware deployment scripts
- Add ENVIRONMENT.md documentation
- Keep personal information in .env (gitignored)

This makes the repository safe for public sharing while keeping personal domains, emails, and secrets secure.
This commit is contained in:
Greg
2025-07-01 10:09:14 -07:00
parent 63b53dfc1b
commit d582108b16
9 changed files with 495 additions and 28 deletions

35
.env.example Normal file
View File

@@ -0,0 +1,35 @@
# Webhook-based Deployment Configuration
# Copy this to .env and customize for your environment
# Webhook Security
WEBHOOK_SECRET=your-webhook-secret-here
# Your Domain Configuration
BASE_DOMAIN=your-domain.com
WEBHOOK_DOMAIN=webhook.your-domain.com
KNATIVE_DOMAIN=your-domain.com
# Application Domains
DEV_DOMAIN=2048-dev.your-domain.com
STAGING_DOMAIN=2048-staging.your-domain.com
PROD_DOMAIN=2048.your-domain.com
# Canonical Knative Domains
DEV_CANONICAL_DOMAIN=game-2048-dev.game-2048-dev.dev.your-domain.com
STAGING_CANONICAL_DOMAIN=game-2048-staging.game-2048-staging.staging.your-domain.com
PROD_CANONICAL_DOMAIN=game-2048-prod.game-2048-prod.your-domain.com
# Paths and Configuration
MANIFESTS_PATH=/home/administrator/k8s-game-2048/manifests
KUBECONFIG_PATH=/etc/rancher/k3s/k3s.yaml
# Deployment Options
DEPLOY_INGRESS=true
WEBHOOK_REPLICAS=1
# GitHub Repository (for container registry)
GITHUB_REPOSITORY=your-username/k8s-game-2048
CONTAINER_REGISTRY=ghcr.io
# Email for SSL certificates
CERT_EMAIL=your-email@your-domain.com