mirror of
https://github.com/arcan1s/ahriman.git
synced 2025-04-24 15:27:17 +00:00
docker hub integration
This commit is contained in:
parent
61efbb71a2
commit
e9886efaa2
29
.github/workflows/docker-image.yml
vendored
Normal file
29
.github/workflows/docker-image.yml
vendored
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
name: docker image
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [ master ]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
docker-image:
|
||||||
|
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: setup QEMU
|
||||||
|
uses: docker/setup-qemu-action@v1
|
||||||
|
|
||||||
|
- name: setup docker buildx
|
||||||
|
uses: docker/setup-buildx-action@v1
|
||||||
|
|
||||||
|
- name: login to docker hub
|
||||||
|
uses: docker/login-action@v1
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: build an image and push
|
||||||
|
uses: docker/build-push-action@v2
|
||||||
|
with:
|
||||||
|
push: true
|
||||||
|
tags: arcan1s/ahriman:latest
|
6
.github/workflows/release.yml
vendored
6
.github/workflows/release.yml
vendored
@ -12,20 +12,24 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: extract version
|
- name: extract version
|
||||||
id: version
|
id: version
|
||||||
run: echo ::set-output name=VERSION::${GITHUB_REF#refs/tags/}
|
run: echo ::set-output name=VERSION::${GITHUB_REF#refs/tags/}
|
||||||
|
|
||||||
- name: create changelog
|
- name: create changelog
|
||||||
id: changelog
|
id: changelog
|
||||||
uses: jaywcjlove/changelog-generator@main
|
uses: jaywcjlove/changelog-generator@main
|
||||||
with:
|
with:
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
filter: 'Release \d+\.\d+\.\d+'
|
filter: 'Release \d+\.\d+\.\d+'
|
||||||
|
|
||||||
- name: create archive
|
- name: create archive
|
||||||
run: make archive
|
run: make archive
|
||||||
env:
|
env:
|
||||||
VERSION: ${{ steps.version.outputs.VERSION }}
|
VERSION: ${{ steps.version.outputs.VERSION }}
|
||||||
- name: Release
|
|
||||||
|
- name: release
|
||||||
uses: softprops/action-gh-release@v1
|
uses: softprops/action-gh-release@v1
|
||||||
with:
|
with:
|
||||||
body: |
|
body: |
|
||||||
|
1
.github/workflows/run-setup.yml
vendored
1
.github/workflows/run-setup.yml
vendored
@ -13,6 +13,7 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: setup the service in arch linux container
|
- name: setup the service in arch linux container
|
||||||
run: |
|
run: |
|
||||||
docker run \
|
docker run \
|
||||||
|
1
.github/workflows/run-tests.yml
vendored
1
.github/workflows/run-tests.yml
vendored
@ -13,6 +13,7 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: run check and tests in arch linux container
|
- name: run check and tests in arch linux container
|
||||||
run: |
|
run: |
|
||||||
docker run \
|
docker run \
|
||||||
|
10
Dockerfile
10
Dockerfile
@ -35,12 +35,12 @@ RUN runuser -u build -- yay --noconfirm -Sy devtools git pyalpm python-inflectio
|
|||||||
## copy tree
|
## copy tree
|
||||||
COPY --chown=build . "/home/build/ahriman"
|
COPY --chown=build . "/home/build/ahriman"
|
||||||
## create package archive and install it
|
## create package archive and install it
|
||||||
RUN cd /home/build/ahriman && \
|
RUN cd "/home/build/ahriman" && \
|
||||||
make VERSION="$(git describe --tags --abbrev=0)" archlinux && \
|
make VERSION=$(python -c "from src.ahriman.version import __version__; print(__version__)") archlinux && \
|
||||||
cp ./*-src.tar.xz package/archlinux && \
|
cp ./*-src.tar.xz "package/archlinux" && \
|
||||||
cd package/archlinux && \
|
cd "package/archlinux" && \
|
||||||
runuser -u build -- makepkg --noconfirm --install --skipchecksums && \
|
runuser -u build -- makepkg --noconfirm --install --skipchecksums && \
|
||||||
cd - && rm -r /home/build/ahriman
|
cd - && rm -r "/home/build/ahriman"
|
||||||
|
|
||||||
VOLUME ["/var/lib/ahriman"]
|
VOLUME ["/var/lib/ahriman"]
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user