Skip to content
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

Automatically set extraheader for both with and without ".git" #54

Closed
sksat opened this issue Feb 7, 2024 · 1 comment · Fixed by #55
Closed

Automatically set extraheader for both with and without ".git" #54

sksat opened this issue Feb 7, 2024 · 1 comment · Fixed by #55
Assignees
Labels
enhancement New feature or request

Comments

@sksat
Copy link
Member

sksat commented Feb 7, 2024

The gh-federation client uses Git's extraheader to automatically checkout the specified repository via gh-federation.
This configuration should specify the exact remote URL to be used for the actual checkout.

Therefore, the current implementation causes inconvenience in the following case.

- uses: arkedge/[email protected]
  with:
    endpoint: ${{ secrets.GH_FEDERATION_ENDPOINT }}
    repos: |
      <your-oug>/<something-internal-repository>

- uses: actions/checkout@v4
  with:
    # "https://github.com/<your-oug>/<something-internal-repository>.git" is in the .gitmodules
    submodules: recursive

In this example, the extraheader is set for the remote URL https://<your-oug>/<something-internal-repository>, but the actual checkout is set for https://<your-oug>/<something-internal-repository>.git, the checkout via gh-federation fails.

@sksat sksat added the enhancement New feature or request label Feb 7, 2024
@sksat
Copy link
Member Author

sksat commented Feb 7, 2024

Alternatively, it may be better to simply add ".git" suffix when configuring extraheader. However, when implementing such an approach, it is necessary to verify the checkout without ".git" so as not to break the existing behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants