26 lines
No EOL
848 B
YAML
26 lines
No EOL
848 B
YAML
when:
|
|
- event: push
|
|
branch: main
|
|
|
|
steps:
|
|
- name: build-x86_64
|
|
image: rust:bookworm
|
|
commands:
|
|
- cargo build --release
|
|
- cp target/release/backend target/backend-amd64
|
|
- name: build-arm64
|
|
image: rust:alpine
|
|
commands:
|
|
- rustup target add aarch64-unknown-linux-musl
|
|
- cargo build --target=aarch64-unknown-linux-musl --release
|
|
- cp target/aarch64-unknown-linux-musl/release/backend target/backend-arm64
|
|
- name: container-build-and-publish
|
|
image: docker
|
|
commands:
|
|
- docker login --username radical --password $PASSWORD git.gorb.app
|
|
- docker buildx build --platform linux/amd64,linux/arm64 --rm --push -t git.gorb.app/gorb/backend:main .
|
|
environment:
|
|
PASSWORD:
|
|
from_secret: docker_password
|
|
volumes:
|
|
- /var/run/podman/podman.sock:/var/run/docker.sock |