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

ci(*): consolidate image/chart workflow for prereleases for correct app version #72

Merged
merged 2 commits into from
Feb 27, 2024

Conversation

vdice
Copy link
Contributor

@vdice vdice commented Feb 16, 2024

For prereleases, we need to know the spin-operator image tag for injecting as the appVersion value in the corresponding Helm chart.

Thus, I've combined image build/publish with chart build/publish for prereleases (i.e. pushes to main) as a way to easily pass the tag down into the chart.

For now, I've left the duties of publishing v* charts in release.yaml since we upload the chart artifact to the GH release. However, this chart artifact could be argued as redundant since it exists in its ghcr.io form (and this is the source that all docs will advise to install from). Therefore, if we don't mind removing this artifact, we can consolidate all chart publishing logic into publish.yaml and reduce release.yaml to just uploading the crds and runtime-class manifests as artifacts and then creating the GH release itself. Thoughts?

Copy link

github-actions bot commented Feb 16, 2024

This PR now has an image available for testing:

  ttl.sh/spoopy-operator-pr-:24h

@endocrimes
Copy link
Contributor

+1 to not bothering with attaching the chart to a github release unless there's eventual demand for it.

Copy link
Contributor

@endocrimes endocrimes left a comment

Choose a reason for hiding this comment

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

mostly lgtm - just looks like it probably needs a rebase

.github/workflows/publish.yaml Outdated Show resolved Hide resolved
@vdice
Copy link
Contributor Author

vdice commented Feb 23, 2024

Thanks for the review @endocrimes.

Okay, after deliberating how to best orchestrate publishing of the image, chart and (if v* tag) create the GH release, it felt best to just add the GH release job to publish.yaml. I did this because I didn't want a GH release to be created without making sure both the image and the chart were successfully published. Rather than try to coordinate this dependency chain across workflows, I put 'em all in one. Definitely welcome ideas on a better future workflow state -- but this should get us what we need in the near term!

(Tested on my fork; see https://github.com/vdice/spin-operator/actions)

@vdice
Copy link
Contributor Author

vdice commented Feb 23, 2024

(markdown errors fixed in #103)

…pp version

Signed-off-by: Vaughn Dice <vaughn.dice@fermyon.com>
Makefile Outdated Show resolved Hide resolved
…yaml

Signed-off-by: Vaughn Dice <vaughn.dice@fermyon.com>
@vdice vdice merged commit 0cb93fa into main Feb 27, 2024
10 checks passed
@vdice vdice deleted the ci/app-version branch February 27, 2024 16:27
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.

None yet

4 participants