Skip to content

Conversation

@sanjay20m
Copy link
Contributor

Summary

This patch fixes an issue in the entrypoint.sh scripts for both CentOS 8 and Fedora 35 where the local YUM repository was not being used by default during test runs.

Issue

Even though the script creates a local YUM repository file (local.repo), it was configured with enabled=0, which means it is disabled by default. While yum-config-manager --enable local-repository was called, this is not always reliable in automated or minimal environments (e.g. CI containers) and may fail silently or be skipped.

As a result, any locally built RPM packages are not actually used during testing, making the local-repository setup ineffective.

Fix

  • Changed enabled=0 to enabled=1 directly in the .repo file to ensure it's active by default.
  • Set the correct baseurl using the ${LOCAL_REPO_DIRECTORY} environment variable.
  • Removed the redundant call to yum-config-manager --enable local-repository.

Impact

  • Ensures local RPMs are tested properly in CI.
  • Fixes misleading behavior where the script pretended to use the local repo but didn’t.
  • Helps catch packaging or integration issues earlier in the CI pipeline.

@copy-pr-bot
Copy link

copy-pr-bot bot commented Jul 17, 2025

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

Signed-off-by: Sanjay Jangid <sanjayjangid20m@gmail.com>
Signed-off-by: Sanjay Jangid <sanjayjangid20m@gmail.com>
@sanjay20m
Copy link
Contributor Author

any changes needed !!

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR fixes a critical issue where local YUM repositories were not being enabled by default in CentOS 8 and Fedora 35 test environments, causing locally built RPM packages to be ignored during testing.

  • Changed repository configuration from enabled=0 to enabled=1 to activate local repos by default
  • Updated baseurl to use the ${LOCAL_REPO_DIRECTORY} environment variable instead of hardcoded path
  • Removed unreliable yum-config-manager --enable command that could fail silently in CI environments

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
tests/release/docker/fedora35/entrypoint.sh Updated local repo configuration to enable by default and use correct baseurl
tests/release/docker/centos8/entrypoint.sh Updated local repo configuration to enable by default and use correct baseurl

@ArangoGutierrez ArangoGutierrez self-assigned this Jul 21, 2025
Copy link
Collaborator

@ArangoGutierrez ArangoGutierrez left a comment

Choose a reason for hiding this comment

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

Hey @sanjay20m thanks for the contribution, could you squash the 2 commits into one, thanks!

@sanjay20m
Copy link
Contributor Author

Hey @ArangoGutierrez
I'm currently facing some issues squashing the commits locally due to setup constraints. If possible, could you please squash the commits while merging on your end?

Let me know if you'd prefer I keep trying locally — I’ll do my best. Thanks again for your time and help!

: ${LOCAL_REPO_DIRECTORY:=/local-repository}
if [[ -d ${LOCAL_REPO_DIRECTORY} ]]; then
echo "Setting up local-repository"
createrepo /local-repository
Copy link
Member

Choose a reason for hiding this comment

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

We should also update this to use the envvar.

Copy link
Contributor Author

@sanjay20m sanjay20m Jul 21, 2025

Choose a reason for hiding this comment

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

Use LOCAL_REPO_DIRECTORY in createrepo command
@sanjay20m sanjay20m requested a review from elezar July 21, 2025 13:06
Signed-off-by: Author Name sanjayjangid20m@gmail.com
Signed-off-by: Sanjay Jangid <sanjayjangid20m@gmail.com>
@sanjay20m
Copy link
Contributor Author

Hi @ArangoGutierrez , @elezar

Apologies for the multiple commits made for a single logical change — I encountered some issues and glitches while trying to squash them locally and through GitHub's web interface. I understand the preference for clean commit history, and I truly appreciate your patience.

If possible, could you please squash the commits while merging the PR? I’d be really grateful for your cooperation and understanding.

Thanks again for reviewing and guiding the patch!
Sanjay Jangid

Signed-off-by: Sanjay Jangid <136222049+sanjay20m@users.noreply.github.com>
@sanjay20m
Copy link
Contributor Author

Very sorry, I am trying to fix it, but it is failing due to some issues. Please cooperate...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants