Skip to content

Commit

Permalink
Add release build.
Browse files Browse the repository at this point in the history
  • Loading branch information
ibz committed Jun 11, 2024
1 parent a03570b commit 00b5346
Show file tree
Hide file tree
Showing 4 changed files with 66 additions and 28 deletions.
25 changes: 25 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
on:
push:
branches: [ "master" ]

env:
CARGO_TERM_COLOR: always

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Compile (musl)
id: compile
uses: rust-build/rust-build.action@v1.4.5
with:
RUSTTARGET: x86_64-unknown-linux-musl
UPLOAD_MODE: none
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: Binary
path: |
${{ steps.compile.outputs.BUILT_ARCHIVE }}
${{ steps.compile.outputs.BUILT_CHECKSUM }}
35 changes: 35 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
on:
release:
types: [created]

env:
CARGO_TERM_COLOR: always

jobs:
release:
permissions: write-all
name: release ${{ matrix.target }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- target: x86_64-pc-windows-gnu
archive_type: zip
archive_name: servus-windows
- target: x86_64-unknown-linux-musl
archive_type: tar.gz
archive_name: servus-linux
- target: x86_64-apple-darwin
archive_type: zip
archive_name: servus-macos
steps:
- uses: actions/checkout@v4
- uses: rust-build/rust-build.action@v1.4.5
name: Compile and release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
RUSTTARGET: ${{ matrix.target }}
ARCHIVE_TYPES: ${{ matrix.archive_type }}
ARCHIVE_NAME: ${{ matrix.archive_name }}
28 changes: 0 additions & 28 deletions .github/workflows/rust.yml

This file was deleted.

6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -212,3 +212,9 @@ The *admin interface* requires you to have a Nostr extension such as [Alby](http
## Any questions?

If you read this far without giving up and still want to try it yourself, feel free to open GitHub issues with any problems you encounter and I'll try to help. I currently use *Servus* to run two live sites, but it is probably not for everyone, yet...

## Want to try it out?

On Linux, use: `wget https://github.com/servuscms/servus/releases/latest/download/servus-linux.tar.gz && tar xzfv servus-linux.tar.gz && ./servus`

Windows and OSX builds are also available from the GitHub [release page](https://github.com/servuscms/servus/releases/latest)!

0 comments on commit 00b5346

Please sign in to comment.