question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Investigate support for GitHub Enterprise

See original GitHub issue

The URL that we pass to CodeBuild to check out the code is currently hard-coded to use https://github.com. Because GitHub Actions is available in GitHub Enterprise, it would be nice if this action worked there too.

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

5reactions
ctdcommented, Mar 20, 2020

The current implementation is also incompatible with private repositories on GitHub.

I have an idea to solve this by having the option to push a source archive (zip/tarball) from GitHub Actions to an S3 bucket, and using this as the source for CodeBuild — rather than having CodeBuild clone from GitHub itself.

This wouldn’t require any additional authentication/authorisation pieces on the GitHub Actions side, and would require a user to give IAM permissions to an S3 bucket in addition to the CodeBuild/Cloudwatch Logs permissions already required.

Is this something you’d consider for this issue, or would you like me to separate this into a new separate issue?

2reactions
matt-tylercommented, Apr 5, 2020

I gave it a go and can confirm that passing GITHUB_ACTOR and the secret variable GITHUB_TOKEN, you can configure a codebuild job with source configured as NO_SOURCE to pull from github. The only issue is that you have to write the step to pull the code within the codebuild buildspec and you miss out on the built-in source caching capabilities of codebuild.

I also hacked it a bit and provided the token as a PLAIN_TEXT environment variable because it was the least amount of work - the current implementation is propogating all environment variables prepend with ‘GITHUB_’ the environment variable overrides. Tokens are valid for roughly 60 minutes according to github documentation, but ideally, they would be configured as secrets in the codebuild startBuild overrides.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Providing data to GitHub Support - GitHub Enterprise Server ...
GitHub Support may ask you to provide additional data in the form of sanitized log files. There are three types of log file...
Read more >
Creating a support ticket - GitHub Enterprise Server 3.3 Docs
Obtain information that can help GitHub Support track, prioritize, reproduce, or investigate the issue. Include full URLs, repository names, and usernames ...
Read more >
GitHub Enterprise Server - GitHub Support
GitHub Support is here to help. Learn about GitHub products, browse our helpful resources, and contact support with your questions.
Read more >
Creating a support ticket - GitHub Docs
Obtain information that can help GitHub Support track, prioritize, reproduce, or investigate the issue. Include full URLs, repository names, and usernames ...
Read more >
Creating a support ticket - GitHub Enterprise Cloud Docs
Obtain information that can help GitHub Support track, prioritize, reproduce, or investigate the issue. Include full URLs, repository names, and usernames ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found