Skip to content

Commit

Permalink
update release process
Browse files Browse the repository at this point in the history
  • Loading branch information
tashima42 committed Jul 24, 2024
1 parent 1e13671 commit e63446d
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 137 deletions.
65 changes: 3 additions & 62 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,68 +18,9 @@ jobs:
make test
make package-binaries
- name: Publish Binaries
uses: SierraSoftworks/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
overwrite: "true"
files: |
${{ github.workspace }}/bin/bootstrap_hash
${{ github.workspace }}/bin/check_for_k8s_release
${{ github.workspace }}/bin/cut_k3s_release_issue
${{ github.workspace }}/bin/cut_rke2_release_issue
${{ github.workspace }}/bin/delete_release_assets
${{ github.workspace }}/bin/rancher_image_scan
${{ github.workspace }}/bin/tag_image_build_k8s_release
${{ github.workspace }}/bin/tag_rke2_packaging_release
${{ github.workspace }}/bin/tag_rke2_release
${{ github.workspace }}/bin/update_go
${{ github.workspace }}/bin/utility_index
${{ github.workspace }}/bin/verify_rke2_charts
${{ github.workspace }}/bin/weekly_report
${{ github.workspace }}/cmd/backport/bin/backport-darwin-amd64
${{ github.workspace }}/cmd/backport/bin/backport-darwin-arm64
${{ github.workspace }}/cmd/backport/bin/backport-linux-amd64
${{ github.workspace }}/cmd/backport/bin/backport-linux-arm64
${{ github.workspace }}/cmd/backport/bin/sha256sums-backport.txt
${{ github.workspace }}/cmd/release/bin/release-darwin-amd64
${{ github.workspace }}/cmd/release/bin/release-darwin-arm64
${{ github.workspace }}/cmd/release/bin/release-linux-amd64
${{ github.workspace }}/cmd/release/bin/release-linux-arm64
${{ github.workspace }}/cmd/release/bin/sha256sums-release.txt
${{ github.workspace }}/cmd/gen_release_report/bin/gen_release_report-darwin-amd64
${{ github.workspace }}/cmd/gen_release_report/bin/gen_release_report-darwin-arm64
${{ github.workspace }}/cmd/gen_release_report/bin/gen_release_report-linux-amd64
${{ github.workspace }}/cmd/gen_release_report/bin/gen_release_report-linux-arm64
${{ github.workspace }}/cmd/gen_release_report/bin/sha256sums-gen_release_report.txt
${{ github.workspace }}/cmd/rancher_release/bin/rancher_release-darwin-amd64
${{ github.workspace }}/cmd/rancher_release/bin/rancher_release-darwin-arm64
${{ github.workspace }}/cmd/rancher_release/bin/rancher_release-linux-amd64
${{ github.workspace }}/cmd/rancher_release/bin/rancher_release-linux-arm64
${{ github.workspace }}/cmd/rancher_release/bin/sha256sums-rancher_release.txt
${{ github.workspace }}/cmd/rke2_release/bin/rke2_release-darwin-amd64
${{ github.workspace }}/cmd/rke2_release/bin/rke2_release-darwin-arm64
${{ github.workspace }}/cmd/rke2_release/bin/rke2_release-linux-amd64
${{ github.workspace }}/cmd/rke2_release/bin/rke2_release-linux-arm64
${{ github.workspace }}/cmd/rke2_release/bin/sha256sums-rke2_release.txt
${{ github.workspace }}/cmd/semv/bin/semv-darwin-amd64
${{ github.workspace }}/cmd/semv/bin/semv-darwin-arm64
${{ github.workspace }}/cmd/semv/bin/semv-linux-amd64
${{ github.workspace }}/cmd/semv/bin/semv-linux-arm64
${{ github.workspace }}/cmd/semv/bin/sha256sums-semv.txt
${{ github.workspace }}/cmd/test_coverage/bin/test_coverage-darwin-amd64
${{ github.workspace }}/cmd/test_coverage/bin/test_coverage-darwin-arm64
${{ github.workspace }}/cmd/test_coverage/bin/test_coverage-linux-amd64
${{ github.workspace }}/cmd/test_coverage/bin/test_coverage-linux-arm64
${{ github.workspace }}/cmd/test_coverage/bin/sha256sums-test_coverage.txt
${{ github.workspace }}/cmd/upstream_go_version/bin/upstream_go_version-darwin-amd64
${{ github.workspace }}/cmd/upstream_go_version/bin/upstream_go_version-darwin-arm64
${{ github.workspace }}/cmd/upstream_go_version/bin/upstream_go_version-linux-amd64
${{ github.workspace }}/cmd/upstream_go_version/bin/upstream_go_version-linux-arm64
${{ github.workspace }}/cmd/upstream_go_version/bin/sha256sums-upstream_go_version.txt
${{ github.workspace }}/ecm-distro-tools.darwin-amd64.tar.gz
${{ github.workspace }}/ecm-distro-tools.darwin-arm64.tar.gz
${{ github.workspace }}/ecm-distro-tools.linux-amd64.tar.gz
${{ github.workspace }}/ecm-distro-tools.linux-arm64.tar.gz
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: gh release upload -R ${{ github.repository }} ${{ github.ref_name }} ${{ github.workspace }}/dist/* --clobber
- name: Docker Hub Login
uses: docker/login-action@v2
with:
Expand Down
22 changes: 13 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -74,20 +74,24 @@ test-image: buildx-machine ## build the container image for all target architecu

.PHONY: package-binaries
package-binaries: $(BINARIES)
@$(eval export BIN_FILES = $(shell ls bin/))
mkdir -p dist
@$(eval export BIN_FILES = $(shell ls -d bin/*))

for binary in $(BINARIES); do \
mv cmd/$${binary}/bin/sha256sums-$${binary}.txt dist/sha256sums-$${binary}.txt; \
done

cp bin/* dist/

for arch in $(ARCHS); do \
for os in $(OSs); do \
SUFFIX=$${os}-$${arch}; \
cd bin && \
tar cvf ../ecm-distro-tools.$${SUFFIX}.tar $(BIN_FILES) && \
cd ../; \
tar cvf dist/ecm-distro-tools.$${SUFFIX}.tar $(BIN_FILES); \
for binary in $(BINARIES); do \
cd cmd/$${binary}/bin && \
tar rvf ../../../ecm-distro-tools.$${SUFFIX}.tar $${binary}-$${SUFFIX} && \
cd ../../../; \
mv cmd/$${binary}/bin/$${binary}-$${SUFFIX} dist/$${binary}-$${SUFFIX} && \
tar rvf dist/ecm-distro-tools.$${SUFFIX}.tar dist/$${binary}-$${SUFFIX}; \
done; \
gzip < ecm-distro-tools.$${SUFFIX}.tar > ecm-distro-tools.$${SUFFIX}.tar.gz && \
rm -f ecm-distro-tools.$${SUFFIX}.tar; \
gzip < dist/ecm-distro-tools.$${SUFFIX}.tar > dist/ecm-distro-tools.$${SUFFIX}.tar.gz && \
rm -f dist/ecm-distro-tools.$${SUFFIX}.tar; \
done; \
done
21 changes: 0 additions & 21 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,6 @@ require (

require (
github.com/MetalBlueberry/go-plotly v0.4.0
github.com/aws/aws-sdk-go v1.52.1
github.com/aws/aws-sdk-go-v2/config v1.27.11
github.com/aws/aws-sdk-go-v2/feature/s3/manager v1.16.15
github.com/aws/aws-sdk-go-v2/service/s3 v1.53.1
github.com/spf13/cobra v1.8.0
github.com/urfave/cli/v2 v2.25.7
golang.org/x/sync v0.7.0
Expand All @@ -31,27 +27,10 @@ require (

require (
dario.cat/mergo v1.0.0 // indirect
github.com/aws/aws-sdk-go-v2 v1.26.1 // indirect
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.6.2 // indirect
github.com/aws/aws-sdk-go-v2/credentials v1.17.11 // indirect
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.16.1 // indirect
github.com/aws/aws-sdk-go-v2/internal/configsources v1.3.5 // indirect
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.6.5 // indirect
github.com/aws/aws-sdk-go-v2/internal/ini v1.8.0 // indirect
github.com/aws/aws-sdk-go-v2/internal/v4a v1.3.5 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.11.2 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.3.7 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.11.7 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.17.5 // indirect
github.com/aws/aws-sdk-go-v2/service/sso v1.20.5 // indirect
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.23.4 // indirect
github.com/aws/aws-sdk-go-v2/service/sts v1.28.6 // indirect
github.com/aws/smithy-go v1.20.2 // indirect
github.com/cloudflare/circl v1.3.7 // indirect
github.com/cyphar/filepath-securejoin v0.2.4 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/jmespath/go-jmespath v0.4.0 // indirect
github.com/pjbgf/sha1cd v0.3.0 // indirect
github.com/skeema/knownhosts v1.2.1 // indirect
github.com/spf13/pflag v1.0.5 // indirect
Expand Down
45 changes: 0 additions & 45 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -14,46 +14,6 @@ github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be h1:9AeTilPcZAjCFI
github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be/go.mod h1:ySMOLuWl6zY27l47sB3qLNK6tF2fkHG55UZxx8oIVo4=
github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPdPJAN/hZIm0C4OItdklCFmMRWYpio=
github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs=
github.com/aws/aws-sdk-go v1.52.1 h1:pYpPIuvVsawYDR0Nt3VrceizUAbtpTN3Z7xBzcZWwfI=
github.com/aws/aws-sdk-go v1.52.1/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk=
github.com/aws/aws-sdk-go-v2 v1.26.1 h1:5554eUqIYVWpU0YmeeYZ0wU64H2VLBs8TlhRB2L+EkA=
github.com/aws/aws-sdk-go-v2 v1.26.1/go.mod h1:ffIFB97e2yNsv4aTSGkqtHnppsIJzw7G7BReUZ3jCXM=
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.6.2 h1:x6xsQXGSmW6frevwDA+vi/wqhp1ct18mVXYN08/93to=
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.6.2/go.mod h1:lPprDr1e6cJdyYeGXnRaJoP4Md+cDBvi2eOj00BlGmg=
github.com/aws/aws-sdk-go-v2/config v1.27.11 h1:f47rANd2LQEYHda2ddSCKYId18/8BhSRM4BULGmfgNA=
github.com/aws/aws-sdk-go-v2/config v1.27.11/go.mod h1:SMsV78RIOYdve1vf36z8LmnszlRWkwMQtomCAI0/mIE=
github.com/aws/aws-sdk-go-v2/credentials v1.17.11 h1:YuIB1dJNf1Re822rriUOTxopaHHvIq0l/pX3fwO+Tzs=
github.com/aws/aws-sdk-go-v2/credentials v1.17.11/go.mod h1:AQtFPsDH9bI2O+71anW6EKL+NcD7LG3dpKGMV4SShgo=
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.16.1 h1:FVJ0r5XTHSmIHJV6KuDmdYhEpvlHpiSd38RQWhut5J4=
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.16.1/go.mod h1:zusuAeqezXzAB24LGuzuekqMAEgWkVYukBec3kr3jUg=
github.com/aws/aws-sdk-go-v2/feature/s3/manager v1.16.15 h1:7Zwtt/lP3KNRkeZre7soMELMGNoBrutx8nobg1jKWmo=
github.com/aws/aws-sdk-go-v2/feature/s3/manager v1.16.15/go.mod h1:436h2adoHb57yd+8W+gYPrrA9U/R/SuAuOO42Ushzhw=
github.com/aws/aws-sdk-go-v2/internal/configsources v1.3.5 h1:aw39xVGeRWlWx9EzGVnhOR4yOjQDHPQ6o6NmBlscyQg=
github.com/aws/aws-sdk-go-v2/internal/configsources v1.3.5/go.mod h1:FSaRudD0dXiMPK2UjknVwwTYyZMRsHv3TtkabsZih5I=
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.6.5 h1:PG1F3OD1szkuQPzDw3CIQsRIrtTlUC3lP84taWzHlq0=
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.6.5/go.mod h1:jU1li6RFryMz+so64PpKtudI+QzbKoIEivqdf6LNpOc=
github.com/aws/aws-sdk-go-v2/internal/ini v1.8.0 h1:hT8rVHwugYE2lEfdFE0QWVo81lF7jMrYJVDWI+f+VxU=
github.com/aws/aws-sdk-go-v2/internal/ini v1.8.0/go.mod h1:8tu/lYfQfFe6IGnaOdrpVgEL2IrrDOf6/m9RQum4NkY=
github.com/aws/aws-sdk-go-v2/internal/v4a v1.3.5 h1:81KE7vaZzrl7yHBYHVEzYB8sypz11NMOZ40YlWvPxsU=
github.com/aws/aws-sdk-go-v2/internal/v4a v1.3.5/go.mod h1:LIt2rg7Mcgn09Ygbdh/RdIm0rQ+3BNkbP1gyVMFtRK0=
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.11.2 h1:Ji0DY1xUsUr3I8cHps0G+XM3WWU16lP6yG8qu1GAZAs=
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.11.2/go.mod h1:5CsjAbs3NlGQyZNFACh+zztPDI7fU6eW9QsxjfnuBKg=
github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.3.7 h1:ZMeFZ5yk+Ek+jNr1+uwCd2tG89t6oTS5yVWpa6yy2es=
github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.3.7/go.mod h1:mxV05U+4JiHqIpGqqYXOHLPKUC6bDXC44bsUhNjOEwY=
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.11.7 h1:ogRAwT1/gxJBcSWDMZlgyFUM962F51A5CRhDLbxLdmo=
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.11.7/go.mod h1:YCsIZhXfRPLFFCl5xxY+1T9RKzOKjCut+28JSX2DnAk=
github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.17.5 h1:f9RyWNtS8oH7cZlbn+/JNPpjUk5+5fLd5lM9M0i49Ys=
github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.17.5/go.mod h1:h5CoMZV2VF297/VLhRhO1WF+XYWOzXo+4HsObA4HjBQ=
github.com/aws/aws-sdk-go-v2/service/s3 v1.53.1 h1:6cnno47Me9bRykw9AEv9zkXE+5or7jz8TsskTTccbgc=
github.com/aws/aws-sdk-go-v2/service/s3 v1.53.1/go.mod h1:qmdkIIAC+GCLASF7R2whgNrJADz0QZPX+Seiw/i4S3o=
github.com/aws/aws-sdk-go-v2/service/sso v1.20.5 h1:vN8hEbpRnL7+Hopy9dzmRle1xmDc7o8tmY0klsr175w=
github.com/aws/aws-sdk-go-v2/service/sso v1.20.5/go.mod h1:qGzynb/msuZIE8I75DVRCUXw3o3ZyBmUvMwQ2t/BrGM=
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.23.4 h1:Jux+gDDyi1Lruk+KHF91tK2KCuY61kzoCpvtvJJBtOE=
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.23.4/go.mod h1:mUYPBhaF2lGiukDEjJX2BLRRKTmoUSitGDUgM4tRxak=
github.com/aws/aws-sdk-go-v2/service/sts v1.28.6 h1:cwIxeBttqPN3qkaAjcEcsh8NYr8n2HZPkcKgPAi1phU=
github.com/aws/aws-sdk-go-v2/service/sts v1.28.6/go.mod h1:FZf1/nKNEkHdGGJP/cI2MoIMquumuRK6ol3QQJNDxmw=
github.com/aws/smithy-go v1.20.2 h1:tbp628ireGtzcHDDmLT/6ADHidqnwgF57XOXZe6tp4Q=
github.com/aws/smithy-go v1.20.2/go.mod h1:krry+ya/rV9RDcV/Q16kpu6ypI4K2czasz0NC3qS14E=
github.com/bwesterb/go-ristretto v1.2.3/go.mod h1:fUIoIZaG73pV5biE2Blr2xEzDoMj7NFEuV9ekS419A0=
github.com/cloudflare/circl v1.3.3/go.mod h1:5XYMA4rFBvNIrhs50XuiBJ15vF2pZn4nnUKZrLbUZFA=
github.com/cloudflare/circl v1.3.7 h1:qlCDlTPz2n9fu58M0Nh1J/JzcFpfgkFHHX3O35r5vcU=
Expand Down Expand Up @@ -124,10 +84,6 @@ github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2
github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw=
github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 h1:BQSFePA1RWJOlocH6Fxy8MmwDt+yVQYULKfN0RoTN8A=
github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99/go.mod h1:1lJo3i6rXxKeerYnT8Nvf0QmHCRC1n8sfWVwXF2Frvo=
github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg=
github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8=
github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
github.com/kevinburke/ssh_config v1.2.0 h1:x584FjTGwHzMwvHx18PXxbBVzfnxogHaAReU4gf13a4=
github.com/kevinburke/ssh_config v1.2.0/go.mod h1:CT57kijsi8u/K/BOFA39wgDQJ9CxiF4nAY/ojJ6r6mM=
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
Expand Down Expand Up @@ -309,7 +265,6 @@ gopkg.in/warnings.v0 v0.1.2 h1:wFXVbFY8DY5/xOe1ECiWdKCzZlxgshcYVNkBHstARME=
gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI=
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY=
gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ=
Expand Down

0 comments on commit e63446d

Please sign in to comment.