-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp.yaml.example
More file actions
114 lines (104 loc) · 2.76 KB
/
app.yaml.example
File metadata and controls
114 lines (104 loc) · 2.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
# DigitalOcean App Platform Specification
# Copy this to app.yaml and configure via DO Console
# DO NOT commit app.yaml with actual secrets!
#
# For deployment:
# 1. Use DO Console to create/update the app
# 2. Set secrets via App Settings → Environment Variables
# 3. Or use: doctl apps create --spec app.yaml.example
alerts:
- rule: DEPLOYMENT_FAILED
- rule: DOMAIN_FAILED
domains:
- domain: yourdomain.com
type: PRIMARY
- domain: www.yourdomain.com
type: ALIAS
envs:
# Non-sensitive configuration (safe to commit)
- key: NODE_ENV
scope: RUN_AND_BUILD_TIME
value: production
- key: STORAGE_PROVIDER
scope: RUN_AND_BUILD_TIME
value: s3
- key: S3_ENDPOINT
scope: RUN_AND_BUILD_TIME
value: https://nyc3.digitaloceanspaces.com
- key: S3_REGION
scope: RUN_AND_BUILD_TIME
value: nyc3
- key: AUTH_TRUST_HOST
scope: RUN_AND_BUILD_TIME
value: "true"
# URLs (configure for your domain)
- key: NEXTAUTH_URL
scope: RUN_AND_BUILD_TIME
value: https://yourdomain.com
- key: NEXT_PUBLIC_APP_URL
scope: RUN_AND_BUILD_TIME
value: https://yourdomain.com
# Email sender (not a secret)
- key: EMAIL_FROM
scope: RUN_AND_BUILD_TIME
value: "YourApp <noreply@yourdomain.com>"
- key: SMTP_FROM
scope: RUN_AND_BUILD_TIME
value: "YourApp <noreply@yourdomain.com>"
- key: VAPID_SUBJECT
scope: RUN_AND_BUILD_TIME
value: mailto:support@yourdomain.com
# =====================================================
# SECRETS - Set these via DO Console, NOT in this file
# =====================================================
# Go to: App → Settings → App-Level Environment Variables
#
# Required secrets to configure:
# - DATABASE_URL (PostgreSQL connection string)
# - DATABASE_URL_DIRECT (Direct connection, bypassing pooler)
# - NEXTAUTH_SECRET (openssl rand -base64 32)
# - ENCRYPTION_KEY (32-char string)
# - CRON_SECRET (openssl rand -base64 32)
# - S3_BUCKET
# - S3_ACCESS_KEY
# - S3_SECRET_KEY
# - CDN_URL
# - RESEND_API_KEY
# - OPENGRAPH_API_KEY (optional)
# - NEXT_PUBLIC_UNSPLASH_ACCESS_KEY (optional)
# - NEXT_PUBLIC_VAPID_PUBLIC_KEY
# - VAPID_PRIVATE_KEY
features:
- buildpack-stack=ubuntu-22
ingress:
rules:
- component:
name: dibs-gifts
match:
authority:
exact: ""
path:
prefix: /
name: dibgifts
region: nyc
services:
- build_command: npm install && npm run migration:up:direct && npm run build
environment_slug: node-js
github:
branch: main
deploy_on_push: true
repo: 312-dev/dibs.gifts
health_check:
failure_threshold: 5
http_path: /api/health
initial_delay_seconds: 30
period_seconds: 10
port: 8080
success_threshold: 1
timeout_seconds: 5
http_port: 8080
instance_count: 1
instance_size_slug: apps-s-1vcpu-0.5gb
name: dibs-gifts
run_command: npm run start -- -p 8080
source_dir: /app