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

Auto release workflow #73

Merged
merged 23 commits into from
Sep 12, 2024
Merged

Conversation

sebastian-quintero
Copy link
Member

@sebastian-quintero sebastian-quintero commented Sep 11, 2024

Description

This PR modifies the release workflow to be automatic. Now we keep two types of versions:

  • The app version: the version used to nextmv community clone the app.
  • The marketplace version: the version used for the marketplace.

The app version is auto-updated based on today’s date and a counter. If the app is release more than once a day, the counter simply increases.

image

The marketplace version is auto-updated by bumping the minor version. There is a new filed in the workflow-configuration.yml file called marketplace_major_version. If that version is changed from v1 to v2, for example, the auto-release workflow will now start updating from v2.0.0 onwards. That is the place where one would specify a new major version being released. If that field is not updated, we will always do a minor bump.

There is a new .nextmv/release folder because the logic started to get complex, so the release script is now a package with multiple files. The main file is .nextmv/release/main.py.

The release.yml workflow was modified to pick up changes on the community apps and do an auto-release.

@sebastian-quintero sebastian-quintero marked this pull request as draft September 11, 2024 22:44
@sebastian-quintero sebastian-quintero marked this pull request as ready for review September 11, 2024 22:44
Comment on lines 17 to +18
type: string
description: "The apps to release with this format: `app-dir1=version1,app-dir2=version2`. E. g.: `go-highs-knapsack=v1.2.0,java-ortools-knapsack=v1.2.0`"
description: "The apps to release, comma separated. E. g.: `go-highs-knapsack,java-ortools-knapsack`"
Copy link
Member

Choose a reason for hiding this comment

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

Will the manual part of this workflow stay? When releasing manually, we should probably not bump the version, right?
I.e., if we run against dev/staging, we don't want to mess with the version of the app in the repo, but rather just push it there, right? 🤔

Copy link
Member Author

Choose a reason for hiding this comment

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

I left the manual dispatch in case we needed to release by hand (although we shouldn't need to). In any case, the inputs are just names, the version is not specified anymore, in neither the manual nor the automated way.

Copy link
Member

@merschformann merschformann left a comment

Choose a reason for hiding this comment

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

Nice! 🎉
Just a remark about potentially skipping version bumps on other environments than prod, just to ensure that there will be no confusion with versions missing from prod (but being in code).

Co-authored-by: Marius Merschformann <marius.merschformann@googlemail.com>
@sebastian-quintero sebastian-quintero marked this pull request as draft September 12, 2024 00:54
@sebastian-quintero sebastian-quintero marked this pull request as ready for review September 12, 2024 00:54
@sebastian-quintero sebastian-quintero merged commit db729c0 into develop Sep 12, 2024
37 checks passed
@sebastian-quintero sebastian-quintero deleted the feature/auto-release-workflow branch September 12, 2024 00:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants