Commit 31c0d7b
feat(deploy): public Fly.io instance + ghcr one-liner (Task 6) (#261)
## Summary
- **fly.toml**: convert from internal-only TCP to public
`[http_service]` (HTTPS 443 → :8090); switch build from Dockerfile to
pre-built `ghcr.io/hyperpolymath/echidna:full` image
- **fly-deploy.yml**: new CI workflow — deploys to
`echidna-nesy.fly.dev` on each release and `workflow_dispatch`
## The two delivery forms (both)
### 1. podman one-liner for colleagues (already works — image is live at
v2.3.0)
```bash
# minimal image (Z3 + Lean) — fastest
podman run --rm -p 8081:8081 ghcr.io/hyperpolymath/echidna:latest server --port 8081 --cors
# full image (all provers + Julia ML) — for serious colleagues
podman run --rm -p 8081:8081 ghcr.io/hyperpolymath/echidna:full server --port 8081 --cors
```
Then in another terminal:
```bash
curl -X POST http://localhost:8081/api/prove \
-H 'content-type: application/json' \
-d '{"prover":"Z3","content":"(set-logic QF_LIA)\n(declare-const x Int)\n(assert (and (> x 0) (< x 0)))\n(check-sat)\n","timeout":30}'
# → {"success":true,...}
```
### 2. Fly.io public instance — one-time setup needed
```bash
# One-time (you do this once):
flyctl apps create echidna-nesy
flyctl tokens create deploy -a echidna-nesy # copy the token
gh secret set FLY_API_TOKEN -b"<token>" -R hyperpolymath/echidna
# Then trigger the workflow (or create a release):
gh workflow run fly-deploy.yml --repo hyperpolymath/echidna
```
After deploy: `https://echidna-nesy.fly.dev/api/health`
## Notes
- The internal `.flycast` URL (`echidna-nesy.flycast:8090`) still works
for `proven-nesy-solver-api` — flycast is automatic and unaffected by
adding `[http_service]`
- `flyctl` is not installed on the dev WSL machine; hence the CI
workflow approach
- `FLY_API_TOKEN` must be set as a repo secret before the workflow can
run
## Test plan
- [ ] Add `FLY_API_TOKEN` repo secret
- [ ] Trigger `fly-deploy.yml` via `workflow_dispatch`
- [ ] Confirm `https://echidna-nesy.fly.dev/api/health` returns
`{"status":"ok",...}`
- [ ] Confirm refutation demo returns `success:true`
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent 6feec89 commit 31c0d7b
2 files changed
Lines changed: 56 additions & 26 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 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 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | | - | |
5 | | - | |
6 | | - | |
| 4 | + | |
| 5 | + | |
7 | 6 | | |
8 | | - | |
9 | | - | |
10 | | - | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
11 | 11 | | |
12 | | - | |
13 | | - | |
14 | | - | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
15 | 17 | | |
16 | 18 | | |
17 | 19 | | |
18 | 20 | | |
19 | 21 | | |
20 | 22 | | |
21 | 23 | | |
22 | | - | |
| 24 | + | |
23 | 25 | | |
24 | 26 | | |
25 | | - | |
26 | | - | |
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
34 | | - | |
35 | | - | |
36 | | - | |
| 34 | + | |
| 35 | + | |
37 | 36 | | |
| 37 | + | |
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
51 | 50 | | |
52 | 51 | | |
53 | 52 | | |
| |||
56 | 55 | | |
57 | 56 | | |
58 | 57 | | |
59 | | - | |
| 58 | + | |
60 | 59 | | |
61 | 60 | | |
0 commit comments