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

Adopt GitHub Actions for CI #189

Merged
merged 3 commits into from
Oct 6, 2023
Merged

Adopt GitHub Actions for CI #189

merged 3 commits into from
Oct 6, 2023

Conversation

davidfurey
Copy link
Member

@davidfurey davidfurey commented Oct 5, 2023

What does this change?

This change adopt GitHub Actions for CI, replacing TeamCity which DevX are switching off in Q2 2023.

This change isn't exactly a no-op switch, as the sbt-riffraff-artifact plugin has been removed in favour of guardian/actions-riff-raff.

How to test

  • Deploy to CODE

Notes

.deb filesize is different between build 187 and build 191, but unzipping yields no differences so I presume this is a quirk of the zip compression

Also switches from deprecated sbt-riffraff-artifact plugin to devx recommendation guardian/actions-riff-raff.

Based on guardian/mobile-n10n#1151 and guardian/s3-upload#53
@davidfurey davidfurey changed the title Migrate from Teamcity to Github actions Adopt GitHub Actions for CI Oct 5, 2023
@davidfurey
Copy link
Member Author

I've done a cursory test in CODE, adding and removing an article from a story package

@davidfurey davidfurey marked this pull request as ready for review October 5, 2023 13:29
@davidfurey davidfurey requested a review from a team October 5, 2023 13:30
Comment on lines +37 to +38
java-version: '8'
distribution: 'corretto'

Choose a reason for hiding this comment

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

Adding cache: 'sbt' here is apparently helpful for performance, I learnt here.

id-token: write
contents: read
steps:
- uses: actions/checkout@v3

Choose a reason for hiding this comment

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

There's a v4 of this action.

steps:
- uses: actions/checkout@v3

- uses: aws-actions/configure-aws-credentials@v2

Choose a reason for hiding this comment

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

Also a v4 of this.

grunt --stack bundle

- name: SBT
run: sbt "clean;compile;test;assets;Debian / packageBin"

Choose a reason for hiding this comment

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

Just a note on batch mode, apparently it makes builds run more slowly. Having said that, this discussion suggests that these sbt commands will run in batch mode, and sequentially (i.e. no need for semicolons either), anyway.

I believe you can also remove the space and have Debian/packageBin, to remove the need for quotes.

Copy link

@samanthagottlieb samanthagottlieb left a comment

Choose a reason for hiding this comment

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

Looks good!

@davidfurey
Copy link
Member Author

Thanks @samanthagottlieb, I'll merge+deploy tomorrow

@davidfurey davidfurey merged commit 1271758 into main Oct 6, 2023
1 check passed
@prout-bot
Copy link

Seen on PROD (merged by @davidfurey 7 minutes and 36 seconds ago) Please check your changes!

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

Successfully merging this pull request may close these issues.

3 participants