Skip to content

Commit

Permalink
Binary with goreleaser
Browse files Browse the repository at this point in the history
aceberg committed Jan 3, 2025
1 parent 376a5ae commit 2bc3348
Showing 15 changed files with 138 additions and 59 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/binary-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Binary-release

on:
workflow_dispatch:
release:
types: [created]

jobs:
generate:
name: Create release-artifacts
runs-on: ubuntu-latest
steps:
- name: Checkout the repository
uses: actions/checkout@master

- uses: actions/setup-go@v4
with:
go-version: 'stable'
- run: go version

- uses: goreleaser/goreleaser-action@v6
with:
distribution: goreleaser
version: latest
args: release --clean
workdir: backend
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
1 change: 1 addition & 0 deletions .version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
VERSION=0.1.0
8 changes: 2 additions & 6 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -3,10 +3,6 @@
All notable changes to this project will be documented in this file.


## [1.0.0] - 2023-07-25
## [0.1.0] - 2025-01-03
### Added
- One thing

### Changed

### Fixed
- First binary release with `goreleaser`
17 changes: 0 additions & 17 deletions Dockerfile

This file was deleted.

2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2024 Andrew Erlikh
Copyright (c) 2025 Andrew Erlikh

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -3,9 +3,7 @@
</a>AnyAppStart</h1>
<br/>

[![Main-Docker](https://github.com/aceberg/AnyAppStart/actions/workflows/main-docker.yml/badge.svg)](https://github.com/aceberg/AnyAppStart/actions/workflows/main-docker.yml)

Supports Docker, Systemd
Start/Stop Docker, Systemd and other apps

![Screenshot](https://raw.githubusercontent.com/aceberg/AnyAppStart/refs/heads/main/assets/Screenshot_05.png)

50 changes: 50 additions & 0 deletions backend/.goreleaser.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
project_name: AnyAppStart
builds:
- main: ./cmd/AnyAppStart/
binary: AnyAppStart
id: default
env: [CGO_ENABLED=0]
goos:
- linux
goarch:
- 386
- amd64
- arm
- arm64
goarm:
- "5"
- "6"
- "7"

nfpms:
- maintainer: aceberg <[email protected]>
description: Start/Stop Docker, Systemd and other apps
homepage: https://github.com/aceberg/AnyAppStart
license: MIT
section: utils
formats:
- deb
- rpm
- apk
- termux.deb
contents:
- src: ./configs/AnyAppStart.service
dst: /lib/systemd/system/AnyAppStart.service
- src: ./configs/[email protected]
dst: /lib/systemd/system/[email protected]
scripts:
postinstall: ./configs/postinstall.sh

archives:
- files:
- LICENSE
- src: ./configs/AnyAppStart.service
dst: AnyAppStart.service
- src: ./configs/[email protected]
dst: [email protected]
- src: ./configs/install.sh
dst: install.sh
wrap_in_directory: true

checksum:
name_template: "checksums.txt"
21 changes: 21 additions & 0 deletions backend/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2025 Andrew Erlikh

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Original file line number Diff line number Diff line change
@@ -5,7 +5,7 @@ After=network-online.target
Wants=network-online.target

[Service]
ExecStart=/usr/bin/AnyAppStart -c /etc/AnyAppStart/config.yaml
ExecStart=/usr/bin/AnyAppStart -d /etc/AnyAppStart
Restart=on-failure

[Install]
Original file line number Diff line number Diff line change
@@ -6,7 +6,7 @@ Wants=network-online.target

[Service]
User=%i
ExecStart=/usr/bin/AnyAppStart -c /home/%i/.config/AnyAppStart/config.yaml
ExecStart=/usr/bin/AnyAppStart -d /home/%i/.config/AnyAppStart
Restart=on-failure

[Install]
File renamed without changes.
3 changes: 3 additions & 0 deletions backend/configs/postinstall.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/sh

systemctl daemon-reload
12 changes: 12 additions & 0 deletions backend/configs/types.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
Docker:
Logs: docker logs
Restart: docker restart
Start: docker start
State: docker ps --filter status=running | grep
Stop: docker stop
Systemd:
Logs: sudo systemctl status
Restart: sudo systemctl restart
Start: sudo systemctl start
State: sudo systemctl | grep running | grep
Stop: sudo systemctl stop
34 changes: 17 additions & 17 deletions backend/internal/web/public/assets/index.js

Large diffs are not rendered by default.

13 changes: 0 additions & 13 deletions docker-compose.yml

This file was deleted.

0 comments on commit 2bc3348

Please sign in to comment.