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

[release/1.2.x] Onboard to CRT #12277

Merged
merged 18 commits into from
Apr 14, 2022
Merged

[release/1.2.x] Onboard to CRT #12277

merged 18 commits into from
Apr 14, 2022

Conversation

claire-labry
Copy link
Collaborator

@claire-labry claire-labry commented Mar 14, 2022

Onboard Nomad OSS [release/1.2.x] to Common Release Tooling

There are a few important changes to call out in this PR:

GitHub Actions is being used as the CI provider to build the go binary artifacts and linux packages. This logic lives in .github/workflows/build.yml and workflow runs are available under https://github.com/hashicorp/nomad/actions.
Artifact builds will continue to run on PR's and merges to main. This behavior can be changed by updating the on: logic in the .github/workflows/build.yml file.

The .release/ci.hcl file contains some metadata for our release service. The only part you'll likely ever need to change is the release_branches array -- when you want to release off of a new release branch, update this value to the release branch name and be sure to update the branches array in .github/workflows/build.yml to the same value. This should be set to either main, the release branch that we'll be releasing off of (once release branches are adopted), or a test branch that you are working off of if you need to validate every part of the pipeline before merging.

  • Clean up this branch before merging [slack ID and branch naming from onboarding tests]

This PR includes the Generate Static Assets workflow-- this workflow generates the static files that are needed for release day. It commits any generated static files that were made into the release branch. These files will either be committed (if files are generated) or no files will be pushed based on the changes that are pushed up.

image

@claire-labry claire-labry requested review from sarahethompson, a team and mdeggies and removed request for a team March 14, 2022 19:02
echo "no files were updated"
fi
- name: Invoke build workflow
uses: benc-uk/workflow-dispatch@4c044c1613fabbe5250deadc65452d54c4ad4fc7
Copy link
Contributor

Choose a reason for hiding this comment

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

Instead of using a workflow dispatch here, we could use the builtin workflow_run.
See docs here: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#onworkflow_runbranchesbranches-ignore
and here: https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#workflow_run

So the opening part of the build.yml would look like:

on:
  workflow_run:
    workflows: [Generate Static Assets]
    types:
      - completed

Copy link
Contributor

Choose a reason for hiding this comment

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

Nevermind, this workflow would have to be on the default branch!

Copy link
Collaborator

@sarahethompson sarahethompson Apr 5, 2022

Choose a reason for hiding this comment

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

@kpenfound - we tried this 😢 but unfortunately it only triggers on the default branch and we want this to run on commits to the release branches

Copy link
Contributor

@kpenfound kpenfound left a comment

Choose a reason for hiding this comment

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

🚀

@vercel vercel bot temporarily deployed to Preview – nomad April 14, 2022 22:10 Inactive
@lgfa29 lgfa29 merged this pull request into release/1.2.x Apr 14, 2022
@lgfa29 lgfa29 deleted the crt/1.2.x branch April 14, 2022 22:39
lgfa29 added a commit that referenced this pull request Apr 14, 2022
Co-authored-by: Sarah <[email protected]>
Co-authored-by: Luiz Aoqui <[email protected]>
@shoenig shoenig mentioned this pull request Jun 2, 2022
@github-actions
Copy link

I'm going to lock this pull request because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active contributions.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 20, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants