Skip to content

Fix V2 API

Fix V2 API #119

name: Push containers
on:
push:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: bazel-contrib/[email protected]
with:
bazelisk-cache: true
disk-cache: ${{ github.workflow }}
repository-cache: true
- name: Log into GHCR
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u "${{ github.actor }}" --password-stdin
- name: Push containers
run: |
export BUILD_TAG="${GIT_COMMIT:-$(git describe --tags --long --always)}"
bazel build //apollo/server/static
rm -rf apollo/server/static/*
cp bazel-bin/apollo/server/static/*.css apollo/server/static/
cp bazel-bin/apollo/server/static/*.js apollo/server/static/
cp bazel-bin/apollo/server/static/*.map apollo/server/static/
docker build -t ghcr.io/resf/apollo-server:$BUILD_TAG -f apollo/server/Dockerfile .
docker build -t ghcr.io/resf/apollo-rpmworker:$BUILD_TAG -f apollo/rpmworker/Dockerfile .
docker build -t ghcr.io/resf/apollo-rhworker:$BUILD_TAG -f apollo/rhworker/Dockerfile .
docker push ghcr.io/resf/apollo-server:$BUILD_TAG
docker push ghcr.io/resf/apollo-rpmworker:$BUILD_TAG
docker push ghcr.io/resf/apollo-rhworker:$BUILD_TAG