-
-
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.
Adds Github Actions package publication + Docker Publication
- Loading branch information
Showing
3 changed files
with
31 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
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,29 @@ | ||
name: Build Image & Publish Package | ||
|
||
on: | ||
push: | ||
tags: | ||
- '*' | ||
|
||
jobs: | ||
build-docker-and-package: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v1 | ||
- name: Installing dependencies | ||
run: | | ||
sudo apt update && sudo apt install make -y | ||
git clone https://github.com/estesp/manifest-tool && cd manifest-tool && git checkout v0.9.0 && sudo make && sudo make install && cd .. && rm -Rf manifest-tool | ||
docker run --rm --privileged multiarch/qemu-user-static:register | ||
sudo apt install -y qemu qemu-user-static qemu-user binfmt-support | ||
echo "${{ secrets.DOCKER_HUB_PASSWORD }}" | docker login -u "${{ secrets.DOCKER_HUB_LOGIN }}" --password-stdin | ||
sudo apt update && sudo apt install make python3-pip python3-setuptools -y | ||
pip3 install twine | ||
- name: Build package | ||
run: make install | ||
- name: Publish package | ||
run: python3 -m twine upload dist/* -u "${{ secrets.PYPI_USERNAME }}" -p "${{ secrets.PYPI_PASSWORD }}" | ||
- name: Build image | ||
run: make build-docker | ||
- name: Publish image | ||
run: make publish-docker latest |