-
-
Notifications
You must be signed in to change notification settings - Fork 553
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Future autobuilds #66
Comments
A change to GitHub Actions? Similar to https://github.com/mbattista/neko/blob/github-actions/.github/workflows/arm-builder.yml |
That'd be also a good idea. Thanks, gonna try that. |
Came up with this (not tested yet). But I feel like, there is too much repetition. I am considering creating one automatic script that would loop through the name: "CI for builds"
on:
push:
branches: [ dev ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check Out Repo
uses: actions/checkout@v2
- name: Login to Docker Hub
run: |
docker login --username ${DOCKERHUB_USERNAME} --password-stdin <<< "${DOCKERHUB_TOKEN}"
env:
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build base
run: |
.m1k1o/build ${DOCKER_TAG}
docker push m1k1o/neko:${DOCKER_TAG}
env:
DOCKER_TAG: base
- name: Build firefox
run: |
.m1k1o/build ${DOCKER_TAG}
docker push m1k1o/neko:${DOCKER_TAG}
#
# Push as well as :latest
#
docker tag m1k1o/neko:${DOCKER_TAG} m1k1o/neko:latest
docker push m1k1o/neko:latest
env:
DOCKER_TAG: firefox
- name: Build chromium
run: |
.m1k1o/build ${DOCKER_TAG}
docker push m1k1o/neko:${DOCKER_TAG}
env:
DOCKER_TAG: chromium
- name: Build google-chrome
run: |
.m1k1o/build ${DOCKER_TAG}
docker push m1k1o/neko:${DOCKER_TAG}
env:
DOCKER_TAG: google-chrome
- name: Build ungoogled-chromium
run: |
.m1k1o/build ${DOCKER_TAG}
docker push m1k1o/neko:${DOCKER_TAG}
env:
DOCKER_TAG: ungoogled-chromium
- name: Build tor-browser
run: |
.m1k1o/build ${DOCKER_TAG}
docker push m1k1o/neko:${DOCKER_TAG}
env:
DOCKER_TAG: tor-browser
- name: Build vncviewer
run: |
.m1k1o/build ${DOCKER_TAG}
docker push m1k1o/neko:${DOCKER_TAG}
env:
DOCKER_TAG: vncviewer
- name: Build vlc
run: |
.m1k1o/build ${DOCKER_TAG}
docker push m1k1o/neko:${DOCKER_TAG}
env:
DOCKER_TAG: vlc
- name: Build xfce
run: |
.m1k1o/build ${DOCKER_TAG}
docker push m1k1o/neko:${DOCKER_TAG}
env:
DOCKER_TAG: xfce And it also does not run in parallel, what would be also good. |
You are right, I changed my example to show parallel builds. My suggestion for the main project:
|
That looks way more cleaner, thanks for your suggestion. About Having these secrets: DOCKER_IMAGE="m1k1o/neko"
DOCKER_REGISTRY="docker.io"
DOCKER_USERNAME
DOCKER_TOKEN Having contition like this (not sure if that would work): if: secrets.DOCKER_IMAGE && secrets.DOCKER_USERNAME && secrets.DOCKER_TOKEN And replaced login action with this: - name: Login to Docker Hub
run: |
docker login --username "${DOCKER_USERNAME}" --password-stdin "${DOCKER_REGISTRY}" <<< "${DOCKER_TOKEN}"
env:
DOCKER_REGISTRY: ${{ secrets.DOCKER_REGISTRY }}
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_TOKEN: ${{ secrets.DOCKER_TOKEN }} While modifying build script that takes image as environment variable: - name: Build container
run: |
BUILD_IMAGE=${DOCKER_IMAGE} .m1k1o/build ${DOCKER_TAG}
docker push ${DOCKER_IMAGE}:${DOCKER_TAG}
env:
DOCKER_TAG: ${{ matrix.tags }}
DOCKER_IMAGE: ${{ secrets.DOCKER_IMAGE }} That should give any fork the freedom to push own images by just modifying secrets accordingly. And as for the forks, they can disable actions in the settings or just choose own to be run. Edit: Not possible. :( actions/runner#520 |
Need to find a way how to keep autobuilds work.
The text was updated successfully, but these errors were encountered: