chore: update release workflow#2322
Conversation
|
My recommendation:
|
There is one issue with the YAML files. I couldn't find a way to switch the |
|
|
If at all possible, I want everything related to a release located in Enterprise. I have a good reason for it - our releases require secrets, and the community repository allows untrusted forks. This is ultimately a bad situation, and causes a lot of compromises in the CI, and constant worries if the mitigations are enough or if we're still at risk of leaking anything. Another reason is that our release process is nobody's business - people needn't know anything about JFrog, or the two-step process. By exposing this information here, you are giving adversaries clues for possible attacks. I think the following should happen:
This is perfectly achievable. You do not need to run JReleaser as a Maven plugin. You can run JReleaser as a command-line app - just like we did until now. This will allow you to centralize all config. |
|
Personally, I see doing a release with something that will never be used again as a waste of time. But if you insist, I won't stop you. |
| run: git push -d origin $RELEASE_BRANCH_NAME | ||
|
|
||
| - name: Create release branch and switch to it | ||
| - name: Delete tag from timefold-solver (if exists) |
There was a problem hiding this comment.
Why do we need to delete a tag? Is that in case we are repeating a release of the same version? Can someone already depend on it?
There was a problem hiding this comment.
The tag needs to remain; if we've built something and published it, the tag must never go away.
I'm assuming this exists in case we ever need to re-run CI perhaps due to a later failure? The better solution here is to just fail and delete the tag manually; tags in general should not be deleted. (Unlike branches.)
| find . -name 'pom.xml' | xargs git add | ||
| # Create a compressed file containing all the artifacts | ||
| tar cvzf artifacts.tar.gz target/staging-deploy | ||
| git add artifacts.tar.gz |
There was a problem hiding this comment.
Is this the archive with all the JAR files? If so, why do we push it to the tag? Binaries usually don't belong to SCM. Why not pushing it to jFrog?
| # Restore all the artifacts | ||
| tar xvzf artifacts.tar.gz | ||
| # Remove the artifact file from the release branch | ||
| git rm artifacts.tar.gz |
There was a problem hiding this comment.
Here we are removing the archive, previously added to the git repository. This commit will be visible in the commit history. Even if we remove it, it will stay a part of the git repository's history and as such will be transferred every time the repository is cloned.
There was a problem hiding this comment.
Yes, this will quickly make the repo blow up in size.



This PR updates the release workflow: