-
Notifications
You must be signed in to change notification settings - Fork 140
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
Support Disabling Source Type Override Parameters #57
Comments
Adding another vote for this capability, we do not want the GitHub repository replicated to the CodeBuild job - we wish to manage this ourselves. |
Another vote, we would like to use this action to run already configured code build jobs. |
@robin-aws Is there any update on getting PR #64 reviewed? |
@robin-aws Our organization has a ton of use-cases for this enhancement (and the workaround is fairly painful). Any chance this gets reviewed anytime soon? |
We've simply forked this action and disabled these overrides, so we can use what is specified on the codebuild job. diff --git a/code-build.js b/code-build.js
index 67d2e14..55be488 100644
--- a/code-build.js
+++ b/code-build.js
@@ -152,7 +152,7 @@ async function waitForBuildEndTime(
function githubInputs() {
const projectName = core.getInput("project-name", { required: true });
- const { owner, repo } = github.context.repo;
+ // const { owner, repo } = github.context.repo;
const { payload } = github.context;
// The github.context.sha is evaluated on import.
// This makes it hard to test.
@@ -177,8 +177,8 @@ function githubInputs() {
return {
projectName,
- owner,
- repo,
+ // owner,
+ // repo,
sourceVersion,
buildspecOverride,
envPassthrough,
@@ -188,15 +188,15 @@ function githubInputs() {
function inputs2Parameters(inputs) {
const {
projectName,
- owner,
- repo,
+ // owner,
+ // repo,
sourceVersion,
buildspecOverride,
envPassthrough = [],
} = inputs;
- const sourceTypeOverride = "GITHUB";
- const sourceLocationOverride = `https://github.com/${owner}/${repo}.git`;
+ // const sourceTypeOverride = "GITHUB";
+ // const sourceLocationOverride = `https://github.com/${owner}/${repo}.git`;
const environmentVariablesOverride = Object.entries(process.env)
.filter(
@@ -209,8 +209,8 @@ function inputs2Parameters(inputs) {
return {
projectName,
sourceVersion,
- sourceTypeOverride,
- sourceLocationOverride,
+ // sourceTypeOverride,
+ // sourceLocationOverride,
buildspecOverride,
environmentVariablesOverride,
}; |
@ejohn20 You can try dark-mechanicum/aws-codebuild github action. By default, it does not pass anything but is very flexible in configuration. You literally can override any parameter for the startBuild API call ;) |
The source type override parameter is automatically overridden on the CodeBuild job to the
GITHUB
type and current repository. We have a scenario that requires our CodeBuild job to source from a different location, but would still like to drive the execution of the CodeBuild job from a GitHub action.Can we add a new parameter that allows us to disable the source type override parameters and use the CodeBuild job's default values?
The text was updated successfully, but these errors were encountered: