Add docker build for linux/amd64
This commit is contained in:
parent
1506a3f83d
commit
cf333a252a
3 changed files with 66 additions and 0 deletions
37
.github/workflows/release.yml
vendored
37
.github/workflows/release.yml
vendored
|
|
@ -92,6 +92,12 @@ jobs:
|
|||
files: |
|
||||
target/artifacts/rqbit-linux-static-x86_64
|
||||
|
||||
- name: Archive target/artifacts/rqbit-linux-static-x86_64
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: rqbit-linux-static-x86_64
|
||||
path: target/artifacts/rqbit-linux-static-x86_64
|
||||
|
||||
- name: Build release linux armv6 binary
|
||||
run: rustup target install arm-unknown-linux-gnueabihf &&
|
||||
make release-linux-armv6 &&
|
||||
|
|
@ -132,3 +138,34 @@ jobs:
|
|||
generate_release_notes: true
|
||||
files: |
|
||||
target/artifacts/rqbit-linux-static-aarch64
|
||||
|
||||
build-push-docker:
|
||||
runs-on: ubuntu-latest
|
||||
needs: cross-compile-on-macos
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Download a single artifact
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: rqbit-linux-static-x86_64
|
||||
|
||||
- name: Move the binary to a different place
|
||||
run: mkdir -p target/x86_64/ && mv rqbit-linux-static-x86_64 target/x86_64/rqbit
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ vars.DOCKERHUB_USERNAME }}
|
||||
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
push: true
|
||||
tags: ikatson/rqbit:${{ github.ref_name }}
|
||||
context: target/x86_64/
|
||||
platforms: linux/amd64
|
||||
file: docker/Dockerfile
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue