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: use github actions to publish new tiup releases #1158

Merged
merged 18 commits into from
Feb 26, 2021
Merged

Conversation

AstroProfundis
Copy link
Contributor

@AstroProfundis AstroProfundis commented Feb 25, 2021

What problem does this PR solve?

Use GitHub Actions to automatically compile and publish new releases of TiUP and its builtin components.

This is also related to #1122

What is changed and how it works?

Added a new workflow .github/workflows/release-tiup.yaml to:

  • run on:
    • push to branch ci/gh-* for testing the CI itself
    • push to branch release-* for staging test
    • new release is created for real releasing of new version
  • testing and staging builds are labeled as +staging in the version string and build info, and are published to staging server defined by secret TIUP_SERVER_STAGING
  • release builds are published to production server defined by secret TIUP_SERVER_PROD

So the releasing procedure in the future would be:

  • cherry-pick needed commits to the release-* branch
  • push latest commits of release-* to github, and a staging build is triggered at this step
  • the staging version will be in the format of vx.y.z-rn-ghash where vx.y.z is the last released version, n is the commit count since last released version, and hash is the hash of current commit (this version would be considered less than the last released version as per SemVer definitions)
  • test the staging version to make sure everything is working as expected
  • create a new release on github, the tag for new release will also be created, then the release workflow is triggered to publish to production server

Check List

Tests

  • Integration test
  • Manual test (add detailed scripts or steps below)
    图片

Release notes:

ci: use github actions to publish new releases

@AstroProfundis AstroProfundis added this to the v1.4.0 milestone Feb 25, 2021
@AstroProfundis AstroProfundis self-assigned this Feb 25, 2021
@ti-chi-bot ti-chi-bot added the size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. label Feb 25, 2021
@codecov-io
Copy link

codecov-io commented Feb 25, 2021

Codecov Report

Merging #1158 (1653f84) into master (d5ae317) will decrease coverage by 7.22%.
The diff coverage is 69.23%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1158      +/-   ##
==========================================
- Coverage   53.53%   46.30%   -7.23%     
==========================================
  Files         284      284              
  Lines       20302    20318      +16     
==========================================
- Hits        10868     9408    -1460     
- Misses       7756     9438    +1682     
+ Partials     1678     1472     -206     
Flag Coverage Δ
cluster 32.60% <80.00%> (-12.41%) ⬇️
dm 25.69% <80.00%> (-0.06%) ⬇️
integrate 39.73% <69.23%> (-8.17%) ⬇️
playground 3.12% <83.33%> (+0.18%) ⬆️
tiup 16.54% <68.62%> (+0.18%) ⬆️
unittest 22.82% <8.33%> (-0.03%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
pkg/repository/mirror.go 39.84% <0.00%> (ø)
cmd/mirror.go 48.91% <64.28%> (+0.39%) ⬆️
cmd/root.go 72.94% <100.00%> (+3.71%) ⬆️
components/playground/main.go 37.75% <100.00%> (+0.31%) ⬆️
pkg/version/version.go 92.30% <100.00%> (+7.69%) ⬆️
pkg/cluster/template/config/config.go 0.00% <0.00%> (-100.00%) ⬇️
pkg/cluster/template/scripts/scripts.go 0.00% <0.00%> (-100.00%) ⬇️
pkg/queue/any_queue.go 0.00% <0.00%> (-83.34%) ⬇️
pkg/cluster/template/scripts/tiflash.go 0.00% <0.00%> (-79.60%) ⬇️
pkg/cluster/task/limits.go 0.00% <0.00%> (-68.75%) ⬇️
... and 65 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d5ae317...8ca8a42. Read the comment docs.

@lucklove
Copy link
Member

/lgtm

@ti-chi-bot
Copy link
Member

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • lucklove

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

The full list of commands accepted by this bot can be found here.

Reviewer can indicate their review by writing /lgtm in a comment.
Reviewer can cancel approval by writing /lgtm cancel in a comment.

@ti-chi-bot ti-chi-bot added the status/LGT1 Indicates that a PR has LGTM 1. label Feb 26, 2021
@lucklove
Copy link
Member

/merge

@ti-chi-bot
Copy link
Member

This pull request has been accepted and is ready to merge.

Commit hash: 8ca8a42

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Feb 26, 2021
@ti-chi-bot ti-chi-bot merged commit b2caddd into master Feb 26, 2021
@ti-chi-bot ti-chi-bot deleted the ci/gh-release branch February 26, 2021 07:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. status/can-merge Indicates a PR has been approved by a committer. status/LGT1 Indicates that a PR has LGTM 1.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants