Skip to content

Commit 1e90ac9

Browse files
committed
ci: add Fly.io deployment (deploy/, fly.toml, workflow)
1 parent b2a5573 commit 1e90ac9

File tree

5 files changed

+41
-2
lines changed

5 files changed

+41
-2
lines changed

.github/workflows/deploy.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Deploy to Fly.io
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
deploy:
10+
name: Deploy
11+
runs-on: ubuntu-latest
12+
concurrency: deploy
13+
steps:
14+
- uses: actions/checkout@v4
15+
with:
16+
submodules: true
17+
- uses: superfly/flyctl-actions/setup-flyctl@master
18+
- run: flyctl deploy --remote-only
19+
env:
20+
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}
File renamed without changes.

Dockerfile renamed to deploy/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@ COPY config.json* ./
3434
COPY --from=frontend-builder /build/frontend/dist/ ./frontend/dist/
3535

3636
# Copy deployment files
37-
COPY Caddyfile /etc/caddy/Caddyfile
38-
COPY start.sh ./start.sh
37+
COPY deploy/Caddyfile /etc/caddy/Caddyfile
38+
COPY deploy/start.sh ./start.sh
3939
RUN chmod +x ./start.sh
4040

4141
ENV PORT=8081
File renamed without changes.

fly.toml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
app = 'deepgram-node-text-to-speech'
2+
primary_region = 'iad'
3+
4+
[build]
5+
dockerfile = "deploy/Dockerfile"
6+
7+
[http_service]
8+
internal_port = 8080
9+
force_https = true
10+
auto_stop_machines = 'stop'
11+
auto_start_machines = true
12+
min_machines_running = 0
13+
processes = ['app']
14+
15+
[[vm]]
16+
memory = '256mb'
17+
cpu_kind = 'shared'
18+
cpus = 1
19+
memory_mb = 256

0 commit comments

Comments
 (0)