A forgejo action to build and push
|
||
---|---|---|
.forgejo/workflows | ||
src | ||
test | ||
.gitignore | ||
.rustfmt.toml | ||
action.yml | ||
Cargo.lock | ||
Cargo.toml | ||
Containerfile | ||
README.md |
Build and push action
Simplest usage
jobs:
build-and-push:
runs-on: docker
steps:
- uses: actions/checkout@v3
- uses: https://git.devd.pw/Ryan/build-and-push@main
with:
image: my-image
tags: latest v1.0.0
Different context
jobs:
build-and-push:
runs-on: docker
steps:
- uses: actions/checkout@v3
- uses: https://git.devd.pw/Ryan/build-and-push@main
with:
image: my-image/frontend
tags: latest v1.0.0
file: ./frontend/Containerfile
context: ./frontend
Different repository
jobs:
build-and-push:
runs-on: docker
steps:
- uses: actions/checkout@v3
- uses: https://git.devd.pw/Ryan/build-and-push@main
with:
image: my-image
tags: latest v1.0.0
repository: cr.devd.pw/private
username: ${{ vars.CR_PRIVATE_USERNAME }}
password: ${{ vars.CR_PRIVATE_PASSWORD }}
Build args
jobs:
build-and-push:
runs-on: docker
steps:
- uses: actions/checkout@v3
- uses: https://git.devd.pw/Ryan/build-and-push@main
with:
image: my-image
tags: latest v1.0.0
build-args: |
ARG1=value1
ARG2=value2