File tree Expand file tree Collapse file tree 2 files changed +28
-2
lines changed Expand file tree Collapse file tree 2 files changed +28
-2
lines changed Original file line number Diff line number Diff line change 6060 include : LICENSE,README.md,huly-coder.yaml
6161 tar : all
6262 zip : windows
63- token : ${{ secrets.GITHUB_TOKEN }}
63+ token : ${{ secrets.GITHUB_TOKEN }}
64+ upload-docker :
65+ name : Build & Push Docker Image
66+ runs-on : ubuntu-latest
67+ steps :
68+ - name : Checkout repository
69+ uses : actions/checkout@v4
70+
71+ - name : Set up Docker Buildx
72+ uses : docker/setup-buildx-action@v3
73+
74+ - name : Login to Docker Hub
75+ uses : docker/login-action@v3
76+ with :
77+ username : ${{ secrets.DOCKER_USER }}
78+ password : ${{ secrets.DOCKER_ACCESS_TOKEN }}
79+
80+ - run : echo VERSION=$(grep '^version =' Cargo.toml | cut -d '"' -f 2) >> $GITHUB_ENV
81+
82+ - name : Build and Push
83+ uses : docker/build-push-action@v6
84+ with :
85+ file : Dockerfile
86+ push : true
87+ tags : " ${{ secrets.DOCKER_USER }}/huly-coder:${{ env.VERSION }},${{ secrets.DOCKER_USER }}/huly-coder:latest"
88+ platforms : linux/amd64,linux/arm64
Original file line number Diff line number Diff line change 11# Build stage
2- FROM rust:1.86 AS builder
2+ FROM --platform=$BUILDPLATFORM rust:1.86 AS builder
3+ ARG TARGETPLATFORM
34WORKDIR /usr/src/huly-coder
45COPY . .
56RUN cargo build --release
You can’t perform that action at this time.
0 commit comments