Build docker image and upload to artifacts #10
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
name: Build docker image and upload to artifacts | |
on: | |
workflow_dispatch: | |
release: | |
types: [published] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repo | |
uses: actions/checkout@master | |
with: | |
submodules: 'recursive' | |
- name: Build docker image | |
run: docker build -t kbot:latest . | |
- name: Export docker image | |
run: docker save -o kbot-docker-image.tar kbot:latest | |
- name: Upload artifact | |
if: success() | |
uses: actions/upload-artifact@v3 | |
with: | |
name: docker-image | |
path: kbot-docker-image.tar | |
if-no-files-found: error |