Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/arkaeriit/soft-serve_monitor
A web interface for a soft serve Git server.
https://github.com/arkaeriit/soft-serve_monitor
Last synced: 26 days ago
JSON representation
A web interface for a soft serve Git server.
- Host: GitHub
- URL: https://github.com/arkaeriit/soft-serve_monitor
- Owner: Arkaeriit
- License: bsd-3-clause
- Created: 2021-12-21T22:52:56.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2022-09-12T15:58:27.000Z (over 2 years ago)
- Last Synced: 2023-03-06T21:51:55.010Z (almost 2 years ago)
- Language: Python
- Size: 20.5 KB
- Stars: 5
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Soft Serve monitor
[Soft Serve](https://github.com/charmbracelet/soft-serve) is a very nice git server. It offers a really nice TUI to browse the repositories on the server. Unfortunately, it does not offers a web interface. Here, I want to try to make a tiny web interface to present the git server and list the repositories there.
I use this to give a web interface to my [personal Git server](https://git.bobignou.red).
## What is on the web interface
The web interface offers a home page that list all the repositories in the server. The name of each repository is a link to it's page.
![Home page](https://i.imgur.com/rHGMz2Y.png)
In the page of each repository, there is the command to clone the repository and a render of the README file.
![A repository page](https://i.imgur.com/7F1vRn2.png)
## Configuration
To tell the web server what files to monitor and how to login to the Soft Serve server, a JSON configuration file is needed. The JSON file needs the following fields:
| Field name | Description | Example |
|----------------|---------------------------------------------------------------|--------------------------|
| `ss_host` | The host name of URL of the Soft Serve server. | "git.bobignou.red" |
| `ss_port` | The port used by the Soft Serve server. | 23231 |
| `repos_path` | The path to the folder where the git repositories are located | "/srv/soft-serve/.repos" |
| `monitor_port` | Port uses by the Flask web server. | 8080 |
| `monitor_name` | A name to display to describe the server. | Bobignou |This JSON file should be given as argument when running the Flask server executable.
An example is given as `config.json` in this repository.
## Running the server
This server depends on the following python libraries:
* Flask
* markdownYou need to install them before being able to run it.
Running this server is as easy as running any other Flask server. I use the following systemd service to run it on [my personal server](https://git.bobignou.red).
```
[Unit]
Description=A soft-serve web interface
After=network.target[Service]
Type=simple
# Another Type: forking
User=root
Group=root
WorkingDirectory=/srv/data/soft-serve
ExecStart=/srv/soft-serve/soft-serve_monitor/soft-serve_monitor.py /srv/soft-serve/soft-serve_monitor/config.json
Restart=on-failure[Install]
WantedBy=multi-user.target
```