v0.5.0
Soft Serve v0.5 is here!
This Soft Serve release includes many new features and bug fixes. Now, Soft Serve supports cloning over HTTP(s) and git:// protocols. It can also be used to import Go packages (go-import aware). It also brings preliminary CI/CD support through Git hooks.
Breaking Change
Soft Serve no longer uses a config
repository for configuration. Now, the configs are split into 2 parts, server config, and access config.
Configuration environment variables have changed:
SOFT_SERVE_INITIAL_ADMIN_KEY
is nowSOFT_SERVE_INITIAL_ADMIN_KEYS
.SOFT_SERVE_KEY_PATH
is nowSOFT_SERVE_SSH_KEY_PATH
.SOFT_SERVE_REPO_PATH
is replaced withSOFT_SERVE_DATA_PATH
. However,SOFT_SERVE_DATA_PATH
now points to the parent directory that holds all Soft Serve data and repositories.SOFT_SERVE_BIND_ADDRESS
is nowSOFT_SERVE_SSH_LISTEN_ADDR
.SOFT_SERVE_HOST
andSOFT_SERVE_PORT
are now combined intoSOFT_SERVE_SSH_PUBLIC_URL
. This should be in the form ofssh://HOST[:PORT]
All these environment variables, except SOFT_SERVE_DATA_PATH
, can be defined in config.yaml
. Defining environment variables settings will override the settings defined in config.yaml
.
Migration
You can use soft migrate-config
command to migrate the existing (old) config to the new one. First, make sure you define the following environment variables before running the command:
SOFT_SERVE_KEY_PATH
The path to the server host key.SOFT_SERVE_REPO_PATH
The path to the repository store directory.SOFT_SERVE_BIND_ADDRESS
The address that the server binds to.
By default, this will produce a new data
directory that has the migrated repositories and ssh keys. You can change that using the SOFT_SERVE_DATA_PATH
environment variable.
Server Configuration
The default Soft Serve backend uses SQLite to store access configs, users, and repository metadata. Custom backends can be implemented to support the old behavior (using a config repository).
The server config is stored in config.yaml
under the data
directory.
Access Configuration
Access configuration and users are now managed through the new SSH-based API. Admins can add/remove users using the user
command. Use the pubkey
command to manage user SSH public keys.
Other access configurations like anon-access
and allow-keyless
still exist and can be controlled using the settings
command. These two access settings control the behavior of users using http(s):// and git:// protocols and anonymous users.
Host your own Soft Serve instance
Check out our new post on hosting your own Soft Serve instance.
Issues
Please report any issues and bugs here.
Changelog
New Features
- 2a0d05a: feat(backend): add sqlite backend (@aymanbagabas)
- 0bff6ce: feat(backend): cache repos (@aymanbagabas)
- 4f07abf: feat(backend): collabs & admins interface (@aymanbagabas)
- 399c33e: feat(backend): create default admin user with initial admin keys (@aymanbagabas)
- 43ff02c: feat(backend): hide repository from ui (@aymanbagabas)
- 7da97b1: feat(backend): parse access level (@aymanbagabas)
- f38848d: feat(backend): repo defaultBranch setting & collabs path (@aymanbagabas)
- b6041ef: feat(backend): server backend (@aymanbagabas)
- 5ec5570: feat(backend): validate repo name (@aymanbagabas)
- 53ba263: feat(cmd): add collab & admin ssh cli api (@aymanbagabas)
- 0bfce9c: feat(cmd): add settings server command (@aymanbagabas)
- 0c86b0a: feat(cmd): migrate config command (@aymanbagabas)
- 82c4c60: feat(cmd): support custom hooks (@aymanbagabas)
- 9a80cdb: feat(config): store server config in file (@aymanbagabas)
- 27a5e47: feat(http): use tls keys when provided (@aymanbagabas)
- b957470: feat(log): add log module (@aymanbagabas)
- f819896: feat(log): initialize debug logger (@aymanbagabas)
- 227f178: feat(server): add git hooks (@aymanbagabas)
- ae9cc3e: feat(server): add prometheus stats server (@aymanbagabas)
- 6cd8ca6: feat(server): add pull mirror repos (@aymanbagabas)
- b9cc769: feat(server): add repo mirror & info commands (@aymanbagabas)
- 4277403: feat(server): add tree & blob server commands (@aymanbagabas)
- 468a99f: feat(server): create ssh client keypair (@aymanbagabas)
- 0c6cc32: feat(server): http server (@aymanbagabas)
- 4b148fb: feat(server): log initial admin keys (@aymanbagabas)
- ce5ab22: feat(server): rework git hooks and drop internal server (@aymanbagabas)
- c1cbb40: feat(server): ssh cli api and middleware (@aymanbagabas)
- 6efe531: feat(server): use a separate ssh server for internal commands (@aymanbagabas)
- 2366f90: feat(server): validate username (@aymanbagabas)
- 106c049: feat(ui): format clone url (@aymanbagabas)
- e47f988: feat(ui): navigate to top/botton of readme and files (@aymanbagabas)
- 5302c49: feat(ui): notify copied text (@aymanbagabas)
- e00b19d: feat(ui): use termenv to copy text to clipboard (@aymanbagabas)
- 7d5563b: feat: bump wish and keygen (@aymanbagabas)
- 0a89da1: feat: update readme (@aymanbagabas)
- 3d7eb7b: feat: use context (@aymanbagabas)
- f388af9: feat: use contexts and clean logging (@aymanbagabas)
- 7f3e304: refactor,feat: use soft serve backends, implement git & http servers, remove config repository, manage soft serve from ssh (#231) (@aymanbagabas)
Bug fixes
- 6d9fc69: fix(backend): always import bare repositories (@aymanbagabas)
- 4a52c1b: fix(backend): cache repo rename (@aymanbagabas)
- 64598e6: fix(backend): create renamed parent directory (@aymanbagabas)
- 99447bc: fix(backend): error when repository doesn't exist (@aymanbagabas)
- fb951a3: fix(backend): init repos and hooks (@aymanbagabas)
- bec3df0: fix(backend): list collabs (@aymanbagabas)
- df43bbb: fix(backend): make public key unique (@aymanbagabas)
- aa8fb74: fix(backend): private repos, description, and nested repos names (@aymanbagabas)
- 1bcdbc0: fix(backend): propagate errors (@aymanbagabas)
- d64549c: fix(backend): repo doesn't exist (@aymanbagabas)
- b9f4c77: fix(backend): settings query (@aymanbagabas)
- c5fa66a: fix(backend): use client ssh key to clone ssh repos (@aymanbagabas)
- 8131a22: fix(backend): use subdir collabs path (@aymanbagabas)
- 7948a2c: fix(ci): remove deprecated ifshort linter (@aymanbagabas)
- ee373fb: fix(cmd): add hidden option when importing a repository (@aymanbagabas)
- 4e67940: fix(cmd): conflicting initial admin user (@aymanbagabas)
- 4394217: fix(cmd): hide migrate-config command (@aymanbagabas)
- 6b2baa9: fix(cmd): omit ssh command line port when empty or 22 (@aymanbagabas)
- bdd8612: fix(config): don't use env default value for datapath (@aymanbagabas)
- 4727a5d: fix(config): mkdir before writing config (@aymanbagabas)
- 5513179: fix(config): parse initial admin keys paths (@aymanbagabas)
- fef6f9b: fix(config): reword key path (@aymanbagabas)
- 89e36f2: fix(config): server config tests (@aymanbagabas)
- 2203fe0: fix(config): use abs paths (@aymanbagabas)
- c59c9ff: fix(config): yaml notations (@aymanbagabas)
- 3dfecd9: fix(http): go-get requests (@aymanbagabas)
- 47410de: fix(http): handle nested git repos (@aymanbagabas)
- c0b9c0d: fix(http): index template html (@aymanbagabas)
- 91e9f37: fix(migrate): copy pub key (@aymanbagabas)
- 5d177f5: fix(server): InitialAdminKeys config name (@aymanbagabas)
- 5d8ff39: fix(server): add ssh command to usage (@aymanbagabas)
- 96ddc11: fix(server): add ssh commands for admin keys (@aymanbagabas)
- 5403d15: fix(server): allow keyless (@aymanbagabas)
- 72d793e: fix(server): check allow-keyless when using git protocol (@aymanbagabas)
- 65a0e4d: fix(server): git daemon test error (@aymanbagabas)
- 0ff2f2d: fix(server): hooks config path (@aymanbagabas)
- fd13d1e: fix(server): internal key should have admin access (@aymanbagabas)
- 6483899: fix(server): reduce perms to collab when creating/deleting repos (@aymanbagabas)
- 58ac5a3: fix(server): remove ssh idle timeout (@aymanbagabas)
- 41893d2: fix(server): rename user commands (@aymanbagabas)
- 694a239: fix(server): simplify git hooks invocation (@aymanbagabas)
- 4a5ccff: fix(server): start with context (@aymanbagabas)
- 2625414: fix(server): use canonical repos dir (@aymanbagabas)
- cbc155d: fix(test): increase git daemon test timeout & close db (@aymanbagabas)
- 37fbfa2: fix(ui): check repo access level (@aymanbagabas)
- bdac20b: fix(ui): clear filename statusbar value on event (@aymanbagabas)
- 69c8e80: fix(ui): display readme from .soft-serve repo (@aymanbagabas)
- 0b842d7: fix(ui): empty repo clone command (@aymanbagabas)
- 3db817b: fix(ui): empty repo resize regression (@aymanbagabas)
- 7498560: fix(ui): no items style (@aymanbagabas)
- d2c91b3: fix(ui): shorten commit hash in status bar and when copying (@aymanbagabas)
- d32879a: fix(ui): show repo update time for new repos (@aymanbagabas)
- 04038e7: fix(ui): spinner regression & empty repo (@aymanbagabas)
- 5a13e8b: fix: create client key and config file (@aymanbagabas)
- afc0b57: fix: migrate readme & fix permissions (@aymanbagabas)
- 443e713: fix: server tests (@aymanbagabas)
Dependency updates
- 91a1e40: feat(deps): bump github.com/spf13/cobra from 1.6.1 to 1.7.0 (@dependabot[bot])
Documentation updates
- decc974: docs: add hooks section (@aymanbagabas)
- 64707c9: docs: add ssh config note and fix admin keys env variable (@aymanbagabas)
- 48d696b: docs: readme typos (@aymanbagabas)
- 865532e: docs: update readme (@aymanbagabas)
- d9cba5c: docs: update server settings (@aymanbagabas)
Other work
- b5992cb: Revert "fix(server/cmd): rename hidden command" (@aymanbagabas)
- 02b44f8: feat(backend,ui): add repo project name (@aymanbagabas)
- 94ae6c8: feat(backend/utils): follow symlink to get file contents (@aymanbagabas)
- 3dc7261: fix(server/cmd): ignore git commands (@aymanbagabas)
- d4e11a3: fix(server/cmd): rename hidden command (@aymanbagabas)
- 9c1c342: refactor(git): sanitize repo name (@aymanbagabas)
- 2d5089e: refactor(server): move into modules (@aymanbagabas)
- 1f673f3: refactor(server): use a fixed repos path & drop AccessMethod (@aymanbagabas)
- 3da027a: refactor: move file backend settings path and set default ssh keypath (@aymanbagabas)
- 15528b7: refactor: move ui package to server/ (@aymanbagabas)
- 9280d2a: typo(config): public url comment (@aymanbagabas)
- 07975dd: typo(ssh): add space after port (@aymanbagabas)
Thoughts? Questions? We love hearing from you. Feel free to reach out on Twitter, The Fediverse, or on Discord.