Skip to content
This repository has been archived by the owner on Feb 26, 2023. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
pojntfx committed May 18, 2021
1 parent dbd12ae commit cef2084
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 10 deletions.
26 changes: 22 additions & 4 deletions .github/workflows/docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,12 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up metadata
id: meta
uses: docker/metadata-action@v3
with:
images: pojntfx/liwasc-backend
tags: type=semver,pattern={{version}}
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
Expand All @@ -20,20 +26,32 @@ jobs:
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_TOKEN }}
- name: Build latest image
- name: Build image
uses: docker/build-push-action@v2
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm64/v8,linux/arm/v7
push: false
tags: pojntfx/liwasc-backend:latest
- name: Push latest image
tags: pojntfx/liwasc-backend:unstable
labels: ${{ steps.meta.outputs.labels }}
- name: Push pre-release image to Docker Hub
if: ${{ github.ref == 'refs/heads/main' }}
uses: docker/build-push-action@v2
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm64/v8,linux/arm/v7
push: true
tags: pojntfx/liwasc-backend:latest
tags: pojntfx/liwasc-backend:unstable
labels: ${{ steps.meta.outputs.labels }}
- name: Push release image to Docker Hub
if: startsWith(github.ref, 'refs/tags/v')
uses: docker/build-push-action@v2
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm64/v8,linux/arm/v7
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
17 changes: 13 additions & 4 deletions .github/workflows/hydrun.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,18 +23,27 @@ jobs:
run: hydrun -a amd64,arm64,arm/v7 ./Hydrunfile
- name: Build frontend with hydrun
run: hydrun "./Hydrunfile frontend"
- name: Publish to GitHub releases
- name: Publish pre-release to GitHub releases
if: ${{ github.ref == 'refs/heads/main' }}
uses: marvinpinto/action-automatic-releases@latest
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: "latest"
automatic_release_tag: unstable
prerelease: true
files: |
out/release/liwasc-backend/*
out/release/liwasc-frontend/*
- name: Publish release to GitHub releases
if: startsWith(github.ref, 'refs/tags/v')
uses: marvinpinto/action-automatic-releases@latest
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: false
files: |
out/release/liwasc-backend/*
out/release/liwasc-frontend/*
- name: Publish to GitHub pages
if: ${{ github.ref == 'refs/heads/main' }}
- name: Publish release to GitHub pages
if: startsWith(github.ref, 'refs/tags/v')
uses: JamesIves/[email protected]
with:
branch: gh-pages
Expand Down
2 changes: 1 addition & 1 deletion Hydrunfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

# Install native dependencies
apt update
apt install -y curl make sudo build-essential sqlite3 libprotobuf-dev protobuf-compiler libpcap-dev
apt install -y curl make sudo build-essential sqlite3 protobuf-compiler libpcap-dev

# Fix certificate authorities on armv7
export SSL_CERT_FILE=/etc/ssl/certs/ca-certificates.crt
Expand Down
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ List, wake and scan nodes in a network.
[![Docker CI](https://github.com/pojntfx/liwasc/actions/workflows/docker.yaml/badge.svg)](https://github.com/pojntfx/liwasc/actions/workflows/docker.yaml)
[![Go Reference](https://pkg.go.dev/badge/github.com/pojntfx/liwasc.svg)](https://pkg.go.dev/github.com/pojntfx/liwasc)
[![Matrix](https://img.shields.io/matrix/liwasc:matrix.org)](https://matrix.to/#/#liwasc:matrix.org?via=matrix.org)
[![Docker Pulls](https://img.shields.io/docker/pulls/pojntfx/liwasc-backend?label=docker%20pulls)](https://hub.docker.com/r/pojntfx/liwasc-backend)
[![Binary Downloads](https://img.shields.io/github/downloads/pojntfx/liwasc/total?label=binary%20downloads)](https://github.com/pojntfx/liwasc/releases)

## Overview

Expand Down Expand Up @@ -38,7 +40,7 @@ If you prefer a native installation, static binaries are also available on [GitH
You can install them like so:

```shell
$ curl -L -o /tmp/liwasc-backend https://github.com/pojntfx/liwasc/releases/download/latest/liwasc-backend.linux-$(uname -m)
$ curl -L -o /tmp/liwasc-backend https://github.com/pojntfx/liwasc/releases/latest/download/liwasc-backend.linux-$(uname -m)
$ sudo install /tmp/liwasc-backend /usr/local/bin
$ sudo setcap cap_net_raw+ep /usr/local/bin/liwasc-backend # This allows rootless execution
```
Expand Down

0 comments on commit cef2084

Please sign in to comment.