Skip to content

Commit 331a372

Browse files
committed
Merge branch 'master' of github.com:bbernhard/signal-cli-rest-api
2 parents 7daeecb + e5e2151 commit 331a372

File tree

71 files changed

+3490
-602
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

71 files changed

+3490
-602
lines changed

.github/FUNDING.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
github: bbernhard

.github/workflows/ci.yml

Lines changed: 55 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,28 +10,75 @@ on:
1010

1111
jobs:
1212
setup:
13-
runs-on: ubuntu-latest
13+
runs-on: ubuntu-24.04
1414
steps:
1515
- name: Set up QEMU
16-
uses: docker/setup-qemu-action@v1
16+
uses: docker/setup-qemu-action@v3
1717
- name: Set up Docker Buildx
18-
uses: docker/setup-buildx-action@v1
18+
uses: docker/setup-buildx-action@v3
1919
- name: Available platforms
2020
run: echo ${{ steps.buildx.outputs.platforms }}
21+
- name: Install Podman
22+
run: sudo apt update && sudo apt install -y podman
23+
2124
build:
22-
runs-on: ubuntu-latest
25+
runs-on: ubuntu-24.04
2326
needs: setup
2427
steps:
2528
- uses: actions/checkout@master
2629
with:
2730
ref: ${{ github.ref }}
31+
- name: Login to Docker Hub
32+
uses: docker/login-action@v1
33+
with:
34+
username: ${{ secrets.DOCKERHUB_USERNAME }}
35+
password: ${{ secrets.DOCKERHUB_TOKEN }}
36+
- name: Free up disk space
37+
run: |
38+
# Remove Java (JDKs)
39+
sudo rm -rf /usr/lib/jvm
40+
41+
# Remove .NET SDKs
42+
sudo rm -rf /usr/share/dotnet
43+
44+
# Remove Swift toolchain
45+
sudo rm -rf /usr/share/swift
46+
47+
# Remove Haskell (GHC)
48+
sudo rm -rf /usr/local/.ghcup
49+
50+
# Remove Julia
51+
sudo rm -rf /usr/local/julia*
52+
53+
# Remove Android SDKs
54+
sudo rm -rf /usr/local/lib/android
55+
56+
# Remove Chromium
57+
sudo rm -rf /usr/local/share/chromium
58+
59+
# Remove Microsoft/Edge and Google Chrome builds
60+
sudo rm -rf /opt/microsoft /opt/google
61+
62+
# Remove Azure CLI
63+
sudo rm -rf /opt/az
64+
65+
# Remove PowerShell
66+
sudo rm -rf /usr/local/share/powershell
67+
68+
# Remove CodeQL and other toolcaches
69+
sudo rm -rf /opt/hostedtoolcache
70+
71+
docker system prune -af || true
72+
docker builder prune -af || true
73+
df -h
2874
- name: Build
2975
env:
3076
VERSION: ${{ github.run_number }}
3177
run: |
78+
df -h
3279
echo "Start CI build"
33-
docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
34-
docker buildx create --name multibuilder
35-
docker buildx use multibuilder
36-
docker buildx build --platform linux/amd64,linux/arm64,linux/arm/v7 -t bbernhard/signal-cli-rest-api:${VERSION}-ci .
80+
docker run --privileged --rm tonistiigi/binfmt --install all
81+
podman manifest create build
82+
podman build --format docker --platform linux/amd64,linux/arm64,linux/arm/v7 --manifest localhost/build .
83+
podman manifest push localhost/build docker://docker.io/bbernhard/signal-cli-rest-api:${EPOCHSECONDS}-ci
3784

.github/workflows/release-dev-version.yml

Lines changed: 51 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,18 @@ on:
1010

1111
jobs:
1212
setup:
13-
runs-on: ubuntu-latest
13+
runs-on: ubuntu-24.04
1414
steps:
1515
- name: Set up QEMU
16-
uses: docker/setup-qemu-action@v1
16+
uses: docker/setup-qemu-action@v3
1717
- name: Set up Docker Buildx
18-
uses: docker/setup-buildx-action@v1
18+
uses: docker/setup-buildx-action@v3
1919
- name: Available platforms
2020
run: echo ${{ steps.buildx.outputs.platforms }}
21+
- name: Install Podman
22+
run: sudo apt update && sudo apt install -y podman
2123
release:
22-
runs-on: ubuntu-latest
24+
runs-on: ubuntu-24.04
2325
needs: setup
2426
steps:
2527
- uses: actions/checkout@master
@@ -30,12 +32,52 @@ jobs:
3032
with:
3133
username: ${{ secrets.DOCKERHUB_USERNAME }}
3234
password: ${{ secrets.DOCKERHUB_TOKEN }}
35+
- name: Free up disk space
36+
run: |
37+
# Remove Java (JDKs)
38+
sudo rm -rf /usr/lib/jvm
39+
40+
# Remove .NET SDKs
41+
sudo rm -rf /usr/share/dotnet
42+
43+
# Remove Swift toolchain
44+
sudo rm -rf /usr/share/swift
45+
46+
# Remove Haskell (GHC)
47+
sudo rm -rf /usr/local/.ghcup
48+
49+
# Remove Julia
50+
sudo rm -rf /usr/local/julia*
51+
52+
# Remove Android SDKs
53+
sudo rm -rf /usr/local/lib/android
54+
55+
# Remove Chromium
56+
sudo rm -rf /usr/local/share/chromium
57+
58+
# Remove Microsoft/Edge and Google Chrome builds
59+
sudo rm -rf /opt/microsoft /opt/google
60+
61+
# Remove Azure CLI
62+
sudo rm -rf /opt/az
63+
64+
# Remove PowerShell
65+
sudo rm -rf /usr/local/share/powershell
66+
67+
# Remove CodeQL and other toolcaches
68+
sudo rm -rf /opt/hostedtoolcache
69+
70+
docker system prune -af || true
71+
docker builder prune -af || true
72+
df -h
73+
3374
- name: Release
3475
env:
3576
VERSION: ${{ github.event.inputs.version }}
3677
run: |
37-
echo "Start CI build"
38-
docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
39-
docker buildx create --name multibuilder
40-
docker buildx use multibuilder
41-
docker buildx build --build-arg BUILD_VERSION_ARG=${VERSION} --platform linux/amd64,linux/arm64,linux/arm/v7 -t bbernhard/signal-cli-rest-api:${VERSION}-dev -t bbernhard/signal-cli-rest-api:latest-dev . --push
78+
echo "Start dev build"
79+
docker run --privileged --rm tonistiigi/binfmt --install all
80+
podman manifest create build
81+
podman build --format docker --build-arg BUILD_VERSION_ARG=${VERSION} --manifest localhost/build --platform linux/amd64,linux/arm64,linux/arm/v7 .
82+
podman manifest push localhost/build docker://docker.io/bbernhard/signal-cli-rest-api:${VERSION}-dev
83+
podman manifest push localhost/build docker://docker.io/bbernhard/signal-cli-rest-api:latest-dev

.github/workflows/release-productive-version.yml

Lines changed: 51 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,18 @@ on:
1010

1111
jobs:
1212
setup:
13-
runs-on: ubuntu-latest
13+
runs-on: ubuntu-24.04
1414
steps:
1515
- name: Set up QEMU
16-
uses: docker/setup-qemu-action@v1
16+
uses: docker/setup-qemu-action@v3
1717
- name: Set up Docker Buildx
18-
uses: docker/setup-buildx-action@v1
18+
uses: docker/setup-buildx-action@v3
1919
- name: Available platforms
2020
run: echo ${{ steps.buildx.outputs.platforms }}
21+
- name: Install Podman
22+
run: sudo apt update && sudo apt install -y podman
2123
release:
22-
runs-on: ubuntu-latest
24+
runs-on: ubuntu-24.04
2325
needs: setup
2426
steps:
2527
- uses: actions/checkout@master
@@ -30,12 +32,52 @@ jobs:
3032
with:
3133
username: ${{ secrets.DOCKERHUB_USERNAME }}
3234
password: ${{ secrets.DOCKERHUB_TOKEN }}
35+
- name: Free up disk space
36+
run: |
37+
# Remove Java (JDKs)
38+
sudo rm -rf /usr/lib/jvm
39+
40+
# Remove .NET SDKs
41+
sudo rm -rf /usr/share/dotnet
42+
43+
# Remove Swift toolchain
44+
sudo rm -rf /usr/share/swift
45+
46+
# Remove Haskell (GHC)
47+
sudo rm -rf /usr/local/.ghcup
48+
49+
# Remove Julia
50+
sudo rm -rf /usr/local/julia*
51+
52+
# Remove Android SDKs
53+
sudo rm -rf /usr/local/lib/android
54+
55+
# Remove Chromium
56+
sudo rm -rf /usr/local/share/chromium
57+
58+
# Remove Microsoft/Edge and Google Chrome builds
59+
sudo rm -rf /opt/microsoft /opt/google
60+
61+
# Remove Azure CLI
62+
sudo rm -rf /opt/az
63+
64+
# Remove PowerShell
65+
sudo rm -rf /usr/local/share/powershell
66+
67+
# Remove CodeQL and other toolcaches
68+
sudo rm -rf /opt/hostedtoolcache
69+
70+
docker system prune -af || true
71+
docker builder prune -af || true
72+
df -h
73+
3374
- name: Release
3475
env:
3576
VERSION: ${{ github.event.inputs.version }}
3677
run: |
37-
echo "Start CI build"
38-
docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
39-
docker buildx create --name multibuilder
40-
docker buildx use multibuilder
41-
docker buildx build --build-arg BUILD_VERSION_ARG=${VERSION} --platform linux/amd64,linux/arm64,linux/arm/v7 -t bbernhard/signal-cli-rest-api:${VERSION} -t bbernhard/signal-cli-rest-api:latest . --push
78+
echo "Start productive build"
79+
docker run --privileged --rm tonistiigi/binfmt --install all
80+
podman manifest create build
81+
podman build --format docker --build-arg BUILD_VERSION_ARG=${VERSION} --manifest localhost/build --platform linux/amd64,linux/arm64,linux/arm/v7 .
82+
podman manifest push localhost/build docker://docker.io/bbernhard/signal-cli-rest-api:${VERSION}
83+
podman manifest push localhost/build docker://docker.io/bbernhard/signal-cli-rest-api:latest

CONTRIBUTING.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Contributing
2+
3+
Contributions are welcome, including bug reports, implementing features or writing documentation.
4+
5+
## Dev Environment Setup
6+
7+
The recommended way is to use docker compose:
8+
9+
1. In the `docker-compose.yml` replace the `image: bbernhard/signal-cli-rest-api:latest` for `build: "."`
10+
11+
The development workflow is:
12+
13+
1. Make changes in the source code.
14+
2. Build the image and run a container.
15+
```bash
16+
docker compose build
17+
```
18+
```bash
19+
docker compose up
20+
```
21+
3. Test the changes.
22+
4. Bring the container down.
23+
```bash
24+
docker compose down
25+
```
26+
4. Repeat as many times as needed.
27+
28+
## Building the documentation
29+
30+
Follow the instructions in the docs [readme page](./src/docs/README.md).

0 commit comments

Comments
 (0)