-
Notifications
You must be signed in to change notification settings - Fork 293
[TKN-703, AMM-41] Dockerize CI build, test and lint jobs
#1160
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…use docker compose for build and test jobs. Add vitest and tsup to ts-sdk manifests.
…to changeset CI check.
…rks). Remove memory/kernel settings in CI
| run: yarn install | ||
| - name: Run Lint | ||
| run: yarn lint --output-style static | ||
| - name: Run lint |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think lint needs anything that is not already installed on a github runner. Doing it in docker might be a little overkill
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As we discussed earlier, I will update this once we can add all the rust projects to the same root workspace.
.github/workflows/checks.yml
Outdated
| changeset: | ||
| runs-on: ubuntu-latest | ||
| if: ${{ github.event.pull_request.user.login != 'dependabot[bot]' }} | ||
| if: ${{ !(github.event.pull_request.user.login == 'dependabot[bot]' || contains(github.event.pull_request.labels.*.name, 'skip-changeset')) }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you can also just do yarn changeset --empty or something IIRC
21b7e61 to
651f0d1
Compare
build and test jobsbuild and test jobs
build and test jobsbuild, test and lint jobs
| "@solana/kit": "^2.3.0", | ||
| "codama": "^1.3.7", | ||
| "typescript": "^5.9.3" | ||
| "tsup": "^8.4.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for my own learning, is there a reason why tsup & vitest were added to some package.json files (other than the root)? maybe smth related to the different docker-compose services?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
a421ce9 to
118fa30
Compare
wjthieme
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Send it!
Summary
Dockerizes the CI build and test jobs using
docker-composeprofiles, resolving native runner issues and simplifying the CI configuration.Changes
1. Add
testprofile to docker-compose.ymlplatform: linux/amd64for all test services to ensure consistent x86_64 architecturelitesvmnative bindings which depend on glibc 2.39+ (__isoc23_*symbols). Debian Bookworm (rust:1.84.0) only has glibc 2.36.:roflag for test services because Vitest writes temporary config bundles tonode_modules/.vite-temp/when loading config files. This is safe in the test environment and necessary for proper test execution.test-program: Whirlpool Solana program teststest-program-integration: Legacy SDK integration tests (requires Ubuntu 24.04 for litesvm)test-ts-sdk: TypeScript SDK tests (client, core, tx-sender, whirlpool)test-rust-sdk: Rust SDK library tests with--libflag### 2. Fix litesvm test failuresTests usinglitesvmwere failing on native GitHub runners with OOM errors despite having sufficient memory. Analysis revealed this was a platform/environment issue rather than actual memory exhaustion.Solution: Dockerizing tests with Ubuntu 24.04 provides:Consistent glibc 2.39 environmentReliable test runs without OOM failures3. Simplify CI workflows
Replaced multi-step CI jobs with simple docker-compose commands:
Before:
After:
docker compose --profile build up)docker compose --profile test up)4. Add dockerized lint job