Skip to content

Add native Linux package building to CI without S3 upload#3993

Merged
raramakr merged 6 commits into
mainfrom
users/raramakr/ci-pkgtest
Mar 24, 2026
Merged

Add native Linux package building to CI without S3 upload#3993
raramakr merged 6 commits into
mainfrom
users/raramakr/ci-pkgtest

Conversation

@raramakr
Copy link
Copy Markdown
Contributor

Integrate native package building into the CI workflow by calling
build_native_linux_packages.yml from ci_linux.yml. Packages are built
for both deb and rpm formats but not uploaded to S3.

Changes:

  • Add upload_packages input to build_native_linux_packages.yml (defaults to true for backward compatibility)
  • Make AWS CLI install, credentials config, and S3 upload steps conditional on upload_packages flag
  • Call build_native_linux_packages.yml from ci_linux.yml with upload_packages: false to build packages during CI tests
  • Build both deb and rpm packages via matrix strategy
  • Use rocm_package_version and build_variant_suffix from inputs

This enables package validation during CI while keeping S3 uploads
limited to native packaging workflows triggered individually

@raramakr raramakr marked this pull request as draft March 16, 2026 18:53
@raramakr raramakr force-pushed the users/raramakr/ci-pkgtest branch from 4d30fae to 92490fd Compare March 17, 2026 18:20
@raramakr raramakr marked this pull request as ready for review March 17, 2026 18:52
@nunnikri nunnikri requested review from dileepr1 and geomin12 March 18, 2026 16:07
Comment thread .github/workflows/build_native_linux_packages.yml Outdated
Comment thread .github/workflows/ci_linux.yml
Comment thread .github/workflows/ci_linux.yml Outdated
@raramakr raramakr force-pushed the users/raramakr/ci-pkgtest branch 2 times, most recently from e41e3f2 to a7a2e62 Compare March 19, 2026 17:58
@raramakr raramakr requested a review from geomin12 March 19, 2026 18:19
Comment thread .github/workflows/ci_linux.yml
@raramakr raramakr force-pushed the users/raramakr/ci-pkgtest branch from a7a2e62 to 7f1ed9b Compare March 20, 2026 18:21
@raramakr raramakr requested a review from geomin12 March 20, 2026 21:50
Copy link
Copy Markdown
Contributor

@nunnikri nunnikri left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Copy Markdown
Contributor

@geomin12 geomin12 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh, can we also add the gfx architecture to the job name? I realize it is building for different archs

raramakr added 5 commits March 23, 2026 11:47
  Integrate native package building into the CI workflow by calling
  build_native_linux_packages.yml from ci_linux.yml. Packages are built
  for both deb and rpm formats but not uploaded to S3.

  Changes:
  - Add upload_packages input to build_native_linux_packages.yml
    (defaults to true for backward compatibility)
  - Make AWS CLI install, credentials config, and S3 upload steps
    conditional on upload_packages flag
  - Call build_native_linux_packages.yml from ci_linux.yml with
    upload_packages: false to build packages during CI tests
  - Build both deb and rpm packages via matrix strategy
  - Use rocm_package_version and build_variant_suffix from inputs

  This enables package validation during CI while keeping S3 uploads
  limited to native packaging workflows triggered individually
The build_native_linux_packages workflow doesn't require access to repository secrets, so removing secrets: inherit to limit secret exposure.
@raramakr raramakr force-pushed the users/raramakr/ci-pkgtest branch from 57474fa to a3fe208 Compare March 23, 2026 18:48
@raramakr
Copy link
Copy Markdown
Contributor Author

oh, can we also add the gfx architecture to the job name? I realize it is building for different archs

Done

@raramakr raramakr merged commit ed062b3 into main Mar 24, 2026
101 checks passed
@raramakr raramakr deleted the users/raramakr/ci-pkgtest branch March 24, 2026 00:47
@github-project-automation github-project-automation Bot moved this from TODO to Done in TheRock Triage Mar 24, 2026
Copy link
Copy Markdown
Member

@ScottTodd ScottTodd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for expanding coverage on presubmit.

Here's some post-merge feedback (my review time is limited, but any work on CI workflows needs to be aligned with our plans, the cost of needing to make changes later is higher)

Please also tag related issues when doing work in these areas, #3177 or a sub-issue would apply here (and that issue should be updated now that this is merged)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This workflow is deprecated. Please no new feature work here. Needs to go in https://github.com/ROCm/TheRock/blob/main/.github/workflows/multi_arch_ci_linux.yml instead/also

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We just switched the default pipeline from ci.yml to multi_arch_ci.yml today with #4204. This workflow now only runs on postsubmit or opt-in on PRs with the ci:run-non-multi-arch label.

Docs: https://github.com/ROCm/TheRock/blob/main/docs/development/ci_behavior_manipulation.md#pull-request

Comment on lines 154 to 159
- name: Upload Package repo to S3
if: ${{ !inputs.skip_package_upload }}
id: upload-packages
run: |
echo "Uploading to s3 bucket : ${{ inputs.release_type }}"
python ./build_tools/packaging/linux/upload_package_repo.py \
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should upload to S3 on CI too.

We're planning on reworking the release (CD) workflows to be based on the workflows currently used for CI:

  1. Always upload to therock-ci-artifacts (or therock-ci-artifacts-external) bucket
  2. Release workflows copy those artifacts to a release bucket after testing them

Comment on lines +222 to +223
build_native_linux_packages:
needs: [build_portable_linux_artifacts]
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be moved up in the workflow. Sort by dependency ordering, ROCm core first, then frameworks:

  1. build rocm artifacts
  2. test rocm artifacts
  3. build rocm native linux packages
  4. test rocm native linux packages
  5. build rocm python packages
  6. build pytorch python packages
  7. test pytorch python packages
  8. build jax python packages
  9. test jax python packages

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @ScottTodd for the feedback. This is exactly the plan for native packaging.
The test PR #3126 and multi arch PR #3561 and coming to shape. Once this is fully ready, we will get the same flow as you suggested. This current PR is a stop gap mechanism till these matures and hence the upload was skipped.

chiranjeevipattigidi pushed a commit that referenced this pull request Mar 27, 2026
Integrate native package building into the CI workflow by calling
  build_native_linux_packages.yml from ci_linux.yml. Packages are built
  for both deb and rpm formats but not uploaded to S3.

  Changes:
- Add upload_packages input to build_native_linux_packages.yml (defaults
to true for backward compatibility)
- Make AWS CLI install, credentials config, and S3 upload steps
conditional on upload_packages flag
- Call build_native_linux_packages.yml from ci_linux.yml with
upload_packages: false to build packages during CI tests
  - Build both deb and rpm packages via matrix strategy
  - Use rocm_package_version and build_variant_suffix from inputs

  This enables package validation during CI while keeping S3 uploads
  limited to native packaging workflows triggered individually

---------

Co-authored-by: raramakr <raramakr@amd.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

4 participants