perf(ci): use pre-built container image for Android builds
CI / Lint (pull_request) Canceled after 0s
CI / Test (pull_request) Canceled after 0s
CI / Build Android (pull_request) Canceled after 0s
CI / Build iOS (pull_request) Canceled after 0s

- Add .devcontainer/ci.Dockerfile: bakes Flutter, JDK 17, Android SDK,
  and flutter precache --android into a single Docker image (~2GB, built once)
- ci.yml: build-android uses kryz-ci:latest container — removes 8 redundant
  SDK download steps (Java 17, Flutter, Android SDK, precache, licenses)
  that account for ~35-40 min of the 40-min container spin-up time
- release.yml: build-android uses kryz-ci:latest container — same reduction
  from 13 steps to 8. Also fixes hardcoded 'token ***' -> '$GITEA_TOKEN'
- devcontainer.json: simplified postCreateCommand (removed venv, pip, claude)
  and cleaned up invalid JSON (comments, empty mounts array)

Estimated impact: 40min -> 5-10min first run (with pre-built image),
~2-3min subsequent runs (Docker layer caching)
This commit is contained in:
robot committed 2026-08-03 08:25:50 +00:00
1 parent 19fc5642ad
commit 0fc01646ac
3 files changed
+38 -70

No files matched your search

+1 -5
View File
@@ -1,8 +1,5 @@
{
"name": "kryz-go",
"mounts": [
// "source=/dev/dri,target=/dev/dri,type=bind"
],
"build": {
"dockerfile": "Dockerfile"
},
@@ -14,8 +11,7 @@
]
}
},
"postCreateCommand": "flutter pub get && python3 -m venv .venv && . .venv/bin/activate && pip install --upgrade pip && pip install -r requirements.txt && curl -fsSL https://claude.ai/install.sh | bash",
"postStartCommand": ".venv/bin/activate",
"postCreateCommand": "flutter pub get",
"containerEnv": {
"ANTHROPIC_BASE_URL": "http://192.168.1.108:1234",
"ANTHROPIC_API_KEY": "lmstudio",