750c906d03
Former-commit-id: f4cafe1f9eb8d9460d67ce6cf6430a29a4bb23c1 Former-commit-id: 170f3be1e293e60c0ad126a546eb854f6a1c2b9e [formerly d4f957c102db6225d74fe7878ecb70d53b6e381f] [formerly 039aa610b3fed1a1508a446e5b01d3fc04ad1150 [formerly efc06c1ba6e48a9e6dadd9d2379e12135c6a8b0a [formerly efc06c1ba6e48a9e6dadd9d2379e12135c6a8b0a [formerly efc06c1ba6e48a9e6dadd9d2379e12135c6a8b0a [formerly c34608d6eb1cf3f72abc43df9fb124b5fe1236f7]]]]] Former-commit-id: cf5e86d13b394597e6e9c290fcfeb5a0390df3dc [formerly b97f7715dfc5aeadf6879347c7fff8314ed183c8] Former-commit-id: 5e7811ae38dc3c1a1242ce1cdeb54197d4dd8e6d Former-commit-id: 24eaf2849bc19ef231f849d0d2749d1e09b4bf25 Former-commit-id: ae3398909959456e860b0f6c7ff7f9a0b920fdd2 Former-commit-id: 3d2f32ce03cd0e7b76bef76023050ce34374ab46 [formerly 8dba5ae80f1858b9a3dcf53d111b05765327cca4] Former-commit-id: ff950fff04fb108b32d3ab1ad487782dd6636e46
89 lines
2.3 KiB
YAML
89 lines
2.3 KiB
YAML
name: Build bot
|
|
|
|
on: [push, pull_request]
|
|
|
|
jobs:
|
|
build-linux:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Check out the repo
|
|
uses: actions/checkout@v2
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v1
|
|
- name: Login to DockerHub
|
|
if: github.repository == 'erebe/wstunnel'
|
|
uses: docker/login-action@v1
|
|
with:
|
|
registry: ghcr.io
|
|
username: ${{ github.repository_owner }}
|
|
password: ${{ secrets.CR_PAT }}
|
|
|
|
# - name: wstunnel-builder-cache
|
|
# id: docker_build_wstunnel-cache
|
|
# uses: docker/build-push-action@v2
|
|
# with:
|
|
# push: true
|
|
# tags: ghcr.io/erebe/wstunnel:builder-cache
|
|
# target: builder-cache
|
|
|
|
- name: wstunnel
|
|
id: docker_build_wstunnel
|
|
uses: docker/build-push-action@v2
|
|
with:
|
|
push: ${{ github.repository == 'erebe/wstunnel' && github.ref == 'refs/heads/master' }}
|
|
tags: ghcr.io/erebe/wstunnel:latest
|
|
|
|
- name: extract Artifact
|
|
run: |
|
|
docker cp $(docker create ghcr.io/erebe/wstunnel:latest /bin/sh -c 'sleep 5000'):/ .
|
|
./wstunnel
|
|
|
|
- uses: actions/upload-artifact@v1
|
|
with:
|
|
name: wstunnel-linux-x64
|
|
path: wstunnel
|
|
|
|
build-windows:
|
|
runs-on: windows-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
|
|
# - name: Install stack
|
|
# run: |
|
|
# curl -sSL https://get.haskellstack.org/ | sh
|
|
|
|
- name: Setup GHC
|
|
run: |
|
|
stack setup
|
|
|
|
- name: Build
|
|
run: |
|
|
stack install
|
|
|
|
- uses: actions/upload-artifact@v1
|
|
with:
|
|
name: wstunnel-windows-x64.exe
|
|
path: C:\Users\runneradmin\AppData\Roaming\local\bin\wstunnel.exe
|
|
|
|
|
|
build-macos:
|
|
runs-on: macos-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
|
|
# - name: Install stack
|
|
# run: |
|
|
# curl -sSL https://get.haskellstack.org/ | sh
|
|
|
|
- name: Setup GHC
|
|
run: |
|
|
stack setup
|
|
|
|
- name: Build
|
|
run: |
|
|
stack install
|
|
|
|
- uses: actions/upload-artifact@v1
|
|
with:
|
|
name: wstunnel-macos
|
|
path: /Users/runner/.local/bin/wstunnel
|