catch up with workflow changes

* I was gone for a while and will try to catch up with upstream changes in the next couple of commits
* since git can't know I'm "combining" multiple files, an automatic merge wouldn't work here
* added todo comments on places that will need special attention
* dockerfiles still need merging -> this commit is broken! (only using it to keep track of external changes)
pull/1118/head
Willy 2021-10-02 16:13:42 +02:00
parent e896d8afbc
commit 3f948126a3
No known key found for this signature in database
GPG Key ID: 02E60AE5D9208602
1 changed files with 27 additions and 9 deletions

View File

@ -91,11 +91,13 @@ jobs:
matrix:
platform: [linux]
arch: [386, amd64, arm-7, arm-6, arm64]
# include:
# - platform: darwin
# arch: amd64
# - platform: windows
# arch: amd64
include:
- platform: darwin
arch: 386
- platform: darwin
arch: amd64
- platform: windows
arch: [amd64, 386]
steps:
- uses: actions/checkout@v2
@ -136,7 +138,7 @@ jobs:
- name: Set Windows Build Flags
if: matrix.platform == 'windows'
run: |
echo "BUILD_FLAGS=-extldflags -static" >> $GITHUB_ENV
echo "BUILD_FLAGS=-extldflags -static -buildmode=exe" >> $GITHUB_ENV
echo "XGO_TAGS=netgo osusergo sqlite_omit_load_extension" >> $GITHUB_ENV
shell: bash
@ -179,16 +181,30 @@ jobs:
rm -rf statping.exe
echo "compressed=statping-windows-${{ matrix.arch }}.zip" >> $GITHUB_ENV
- name: Compress Darwin Builds
if: matrix.platform == 'darwin'
# TODO combine these steps?
- name: Compress Darwin 32bit Builds
if: matrix.platform == 'darwin' && matrix.arch == '386'
run: |
cd build
mv statping-darwin-10.6-${{ matrix.arch }} statping
ls >> $GITHUB_ENV
# mv statping-darwin-10.6-${{ matrix.arch }} statping
# chmod +x statping
# tar -czvf statping-darwin-${{ matrix.arch }}.tar.gz *
# rm -rf statping
# echo "compressed=statping-darwin-${{ matrix.arch }}.tar.gz" >> $GITHUB_ENV
- name: Compress Darwin 64bit Builds
if: matrix.platform == 'darwin' && matrix.arch == 'amd64'
run: |
cd build
mv statping-darwin-10.12-${{ matrix.arch }} statping
chmod +x statping
tar -czvf statping-darwin-${{ matrix.arch }}.tar.gz statping
rm -rf statping
echo "compressed=statping-darwin-${{ matrix.arch }}.tar.gz" >> $GITHUB_ENV
# TODO darwin arm64?
- name: Upload Compiled Statping Binary
uses: actions/upload-artifact@v1
with:
@ -528,12 +544,14 @@ jobs:
restore-keys: |
buildx-docker-master
# TODO duplicate login why?
- name: Docker Login
env:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
run: echo "${DOCKER_PASSWORD}" | docker login --username "${DOCKER_USERNAME}" --password-stdin
# TODO get rid of the base image
- name: Docker Build :base
run: make buildx-base