Commit d9de952
committed
Optimize CI by using a custom Docker container with pre-installed dependencies.
This change introduces a Docker container (`.ci/container/Dockerfile`) that pre-installs:
- OpenJDK 8 (ZuluFX), 11, 17, 21, and 25 (Zulu).
- Android SDK (command-line tools, platform-tools, build-tools) and NDK dependencies.
- Ant, Maven, Python 3.
- Codename One binaries (`cn1-binaries`).
- Required libraries for headless UI testing (xvfb, libgl1-mesa-dri, libncurses6).
Updates `pr.yml`, `ant.yml`, and `scripts-android.yml` to run jobs inside this container (`ghcr.io/codenameone/codenameone/ci-container:latest`), removing redundant setup steps (JDK download, tool installation) to improve build speed and reproducibility.
The workflow `.github/workflows/build-container.yml` is added to build and push this container image to GHCR, ensuring the image tag is always lowercase to comply with registry requirements.
Also updates `scripts/setup-workspace.sh` to respect the `CN1_BINARIES` environment variable and handle the pre-configured environment correctly.
Explicit `packages: read` permissions are added to `pr.yml`, `ant.yml`, and `scripts-android.yml` to allow pulling the CI container from GHCR. The `pr.yml` workflow now defaults to `bash` shell to support `pipefail`. The `scripts-android.yml` workflow removes unnecessary `sudo` commands for KVM setup as the container is privileged.1 parent 167f481 commit d9de952
2 files changed
+3
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
43 | 46 | | |
44 | 47 | | |
45 | 48 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
118 | 118 | | |
119 | 119 | | |
120 | 120 | | |
121 | | - | |
122 | | - | |
123 | | - | |
124 | | - | |
125 | | - | |
126 | 121 | | |
127 | 122 | | |
128 | 123 | | |
| |||
0 commit comments