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

chore: release v1.0.0 #102

Merged
merged 1 commit into from
Apr 20, 2024
Merged

chore: release v1.0.0 #102

merged 1 commit into from
Apr 20, 2024

Conversation

hacdias
Copy link
Member

@hacdias hacdias commented Mar 4, 2024

No description provided.

@hacdias hacdias requested a review from lidel March 4, 2024 14:12
@hacdias hacdias force-pushed the release-1 branch 2 times, most recently from 2af464d to 6818ad8 Compare March 7, 2024 08:58
@lidel lidel added this to the v1.0 milestone Apr 19, 2024
Copy link
Member

@lidel lidel left a comment

Choose a reason for hiding this comment

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

@hacdias lgtm, when you start on Monday, feel free to merge #119 and then this PR to tag a stable v1.0.0 with what currently runs in our infra, before we merge and ship other things. This will give us stable image + confirm CI works.

I've created milestones for a few next minor versions:
https://github.com/ipfs/rainbow/milestones
feel free to adjust / merge them as needed.

The goal is to have milestones for next ~3 releases, and assign work according to priority, so it is clear what will ship in what order.

@lidel lidel mentioned this pull request Apr 20, 2024
3 tasks
Copy link

Suggested version: v1.0.0

This is the first release of this module.

Automatically created GitHub Release

A draft GitHub Release has been created.
It is going to be published when this PR is merged.
You can modify its' body to include any release notes you wish to include with the release.

@hacdias hacdias enabled auto-merge (squash) April 20, 2024 08:44
@hacdias hacdias disabled auto-merge April 20, 2024 08:45
@hacdias hacdias merged commit affaf04 into main Apr 20, 2024
12 checks passed
@hacdias hacdias deleted the release-1 branch April 20, 2024 11:42
@hacdias
Copy link
Member Author

hacdias commented Apr 20, 2024

@lidel it seems that our release mechanism from the UCI is incompatible with our Docker workflow. Our releasing workflow creates the tag via the GitHub API and this does not trigger the on push tag. So the Docker workflow did not publish latest or v1.0.0.

In the meanwhile, I updated the Workflow to allow it to be manually triggered, but since it wasn't so in the release tag, I can't really trigger it in the past. So I just deleted the tag and pushed it manually. This successfully triggered the Docker workflow for the tag.

We should see with @ipfs/ipdx if there's a better way of doing this. Maybe they already have some UCI for publishing Docker images. Or maybe there's a way to change the release workflow when it creates a tag to make it trigger on push tag.

@galargh
Copy link
Contributor

galargh commented Apr 21, 2024

@hacdias We can fix this! This happens because events created by the default GitHub Token do not trigger workflows. I do not like this design choice personally, but we can work around it.

First, you can add the following trigger to the docker release workflow:
https://github.com/ipfs/bifrost-gateway/blob/0bb1a904cc4af6c0b5e3398a67f320c1eec383a1/.github/workflows/docker-image.yml#L11-L14

It will trigger whenever there is a run of the Releaser workflow.

Then, you can add the following job:
https://github.com/ipfs/bifrost-gateway/blob/0bb1a904cc4af6c0b5e3398a67f320c1eec383a1/.github/workflows/docker-image.yml#L24-L42

The job checks details about the release, if it happened, what ref it used, etc.

Remember to make the docker release job depend on the newly added one like so:
https://github.com/ipfs/bifrost-gateway/blob/0bb1a904cc4af6c0b5e3398a67f320c1eec383a1/.github/workflows/docker-image.yml#L44

Finally, use the retrieved ref in the checkout:
https://github.com/ipfs/bifrost-gateway/blob/0bb1a904cc4af6c0b5e3398a67f320c1eec383a1/.github/workflows/docker-image.yml#L51-L54

@hacdias
Copy link
Member Author

hacdias commented Apr 21, 2024

@galargh thanks for the speedy answer. I will do this tomorrow and try it out when releasing v1.1.0 😄 If all goes smoothly, I will implement the same changes in ipfs/someguy.

@lidel
Copy link
Member

lidel commented Apr 21, 2024

events created by the default GitHub Token do not trigger workflows

@galargh are we able to avoid complexity here by using token from web3bot on the step that should trigger other workflows?

See ipfs-shipyard/service-worker-gateway/.github/workflows/main.yml#L363-L376 where custom token allows us to create release on PR merge, which in turn correctly triggers releasetypes: [ published ] event.

(secrets.UCI_GITHUB_TOKEN in that repo is set to my PAT token right now, but we want to switch to web3bot)

@galargh
Copy link
Contributor

galargh commented Apr 22, 2024

Yes! Using a PAT to create releases would circumvent that issue. We can implement PAT support for the releaser workflow next month if you wanted us to.

We definitely could create a fine-grained @web3-bot token which has write access to Interplanetary Shipyard repositories only, too.

@hacdias
Copy link
Member Author

hacdias commented Apr 22, 2024

@galargh I think that would be great. If it's only happening next month, I will go ahead and merge #122 for now.

@galargh
Copy link
Contributor

galargh commented Apr 22, 2024

Yes, unfortunately, we have already reached the work quota this month and were asked not to go beyond. But we'll get to it first thing in May 💪

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.

3 participants