From 9c0edad5b94559ae962c6159d5f2943fa6ed0f55 Mon Sep 17 00:00:00 2001 From: Aine Date: Tue, 28 Mar 2023 16:02:22 +0300 Subject: [PATCH] add Soft Serve --- docs/services/soft-serve.md | 30 ++++++++++++++++++++++++++++++ docs/supported-services.md | 1 + group_vars/mash_servers | 26 ++++++++++++++++++++++++++ requirements.yml | 2 ++ setup.yml | 2 ++ 5 files changed, 61 insertions(+) create mode 100644 docs/services/soft-serve.md diff --git a/docs/services/soft-serve.md b/docs/services/soft-serve.md new file mode 100644 index 0000000..2838361 --- /dev/null +++ b/docs/services/soft-serve.md @@ -0,0 +1,30 @@ +# Soft Serve + +This playbook can configure [Soft Serve](https://github.com/charmbracelet/soft-serve). + +## Configuration + +To enable this service, add the following configuration to your `vars.yml` file and re-run the [installation](../installing.md) process: + +```yaml +######################################################################## +# # +# soft-serve # +# # +######################################################################## + +soft_serve_enabled: true +soft_serve_hostname: mash.example.com # an URL Soft Serve will advertise +soft_serve_container_bind_port: 2222 # Expose Soft Serve's port. For git servers the usual git-over-ssh port is 22 +soft_serve_initial_admin_key: YOUR PUBLIC SSH KEY HERE + +######################################################################## +# # +# /soft-serve # +# # +######################################################################## +``` + +## Usage + +After you've installed Soft Serve, you can `ssh your-user@mash.example.com -p 2222` with the ssh key you defined in `soft_serve_initial_admin_key` to see TUI and follow the instructions to configure Soft Serve further. diff --git a/docs/supported-services.md b/docs/supported-services.md index 5b173b8..381a0d7 100644 --- a/docs/supported-services.md +++ b/docs/supported-services.md @@ -27,6 +27,7 @@ | [Radicale](https://radicale.org/) | A Free and Open-Source CalDAV and CardDAV Server (solution for hosting contacts and calendars) | [Link](services/radicale.md) | | [Redmine](https://redmine.org/) | A flexible project management web application. | [Link](services/redmine.md) | | [Redis](https://redis.io/) | An in-memory data store used by millions of developers as a database, cache, streaming engine, and message broker. | [Link](services/redis.md) | +| [Soft Serve](https://github.com/charmbracelet/soft-serve) | A tasty, self-hostable Git server for the command line | [Link](services/soft-serve.md) | | [Syncthing](https://syncthing.net/) | A continuous file synchronization program which synchronizes files between two or more computers in real time | [Link](services/syncthing.md) | | [Traefik](https://doc.traefik.io/traefik/) | A container-aware reverse-proxy server | [Link](services/traefik.md) | | [Vaultwarden](https://github.com/dani-garcia/vaultwarden) | A lightweight unofficial and compatible implementation of the [Bitwarden](https://bitwarden.com/) password manager | [Link](services/vaultwarden.md) | diff --git a/group_vars/mash_servers b/group_vars/mash_servers index 2490530..18de9c8 100644 --- a/group_vars/mash_servers +++ b/group_vars/mash_servers @@ -123,6 +123,8 @@ devture_systemd_service_manager_services_list_auto: | + ([{'name': (redis_identifier + '.service'), 'priority': 750, 'groups': ['mash', 'redis']}] if redis_enabled else []) + + ([{'name': (soft_serve_identifier + '.service'), 'priority': 2000, 'groups': ['mash', 'soft-serve']}] if soft_serve_enabled else []) + + ([{'name': (syncthing_identifier + '.service'), 'priority': 2000, 'groups': ['mash', 'syncthing']}] if syncthing_enabled else []) + ([{'name': (vaultwarden_identifier + '.service'), 'priority': 2000, 'groups': ['mash', 'vaultwarden', 'vaultwarden-server']}] if vaultwarden_enabled else []) @@ -1133,6 +1135,30 @@ redis_gid: "{{ mash_playbook_gid }}" + +######################################################################## +# # +# soft-serve # +# # +######################################################################## + +soft_serve_enabled: false + +soft_serve_identifier: "{{ mash_playbook_service_identifier_prefix }}soft-serve" + +soft_serve_uid: "{{ mash_playbook_uid }}" +soft_serve_gid: "{{ mash_playbook_gid }}" + +soft_serve_base_path: "{{ mash_playbook_base_path }}/{{ mash_playbook_service_base_directory_name_prefix }}soft-serve" + +######################################################################## +# # +# /soft-serve # +# # +######################################################################## + + + ######################################################################## # # # syncthing # diff --git a/requirements.yml b/requirements.yml index 69408f3..1ba4214 100644 --- a/requirements.yml +++ b/requirements.yml @@ -49,6 +49,8 @@ version: v0.23.0-3 - src: git+https://gitlab.com/etke.cc/roles/redmine.git version: v5.0.5-1 +- src: git+https://gitlab.com/etke.cc/roles/soft_serve.git + version: v0.4.6-0 - src: git+https://github.com/mother-of-all-self-hosting/ansible-role-adguard-home.git version: v0.107.26-0 name: adguard_home diff --git a/setup.yml b/setup.yml index 78904fe..f35d358 100644 --- a/setup.yml +++ b/setup.yml @@ -92,6 +92,8 @@ - role: galaxy/redis + - role: galaxy/soft_serve + - role: galaxy/syncthing - role: galaxy/vaultwarden