-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
08f4d42
commit 30aa257
Showing
1 changed file
with
47 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: operator | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- '*' | ||
|
||
env: | ||
REGISTRY: ghcr.io | ||
|
||
jobs: | ||
build: | ||
name: Depot Build | ||
runs-on: depot-ubuntu-22.04-4 | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v2 | ||
|
||
- name: Login to GitHub Container Registry (GHCR) | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: ${{ env.REGISTRY }} | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Setup Depot CLI | ||
uses: depot/setup-action@v1 | ||
env: | ||
DEPOT_TOKEN: ${{ secrets.DEPOT_API_TOKEN }} | ||
|
||
- name: Build and Load Docker Image with Depot | ||
run: | | ||
depot build . \ | ||
--project hs0gfs4l0l \ | ||
--file Dockerfile \ | ||
--tag ${{ env.REGISTRY }}/${{ github.repository }}:latest \ | ||
--platform linux/amd64 \ | ||
--build-arg RELEASE=--release \ | ||
--build-arg ARCH=amd64 \ | ||
--build-arg RELEASE_DIR=release \ | ||
--load | ||
env: | ||
DEPOT_TOKEN: ${{ secrets.DEPOT_API_TOKEN }} |