+<picture>
+ <source media="(prefers-color-scheme: dark)" srcset="dark_logo.png">
+ <source media="(prefers-color-scheme: light)" srcset="light_logo.png">
+ <img src="dark_logo.png" alt="Mobius Logo">
+</picture>
+
# Mobius
-Mobius is a cross-platform command line [Hotline](https://en.wikipedia.org/wiki/Hotline_Communications) server, client, and library developed in Golang.
+Mobius is a cross-platform command line [Hotline](https://en.wikipedia.org/wiki/Hotline_Communications) client and server implemented in Golang.
-The project aims to support Hotline functionality from versions v1.2.3 and >v1.5 (e.g. threaded news and folder transfers).
+The goal of Mobius server is to make it simple to run a Hotline server on macOS, Linux, and Windows, with full compatibility for all popular Hotline clients.
-## Project status
+The goal of the Mobius client is to make it fun and easy to connect to multiple Hotline servers through a [cool retro terminal UI](https://github.com/jhalter/mobius/wiki/Mobius-Client-Screenshot-Gallery).
-### Server
+## Getting started
-* Near feature complete
+### Docker
-### Client
+To quickly run a Hotline server with ports forwarded from the host OS to the container, run:
-* Early stage with functionality for chat and news posting only
+ docker run --rm -p 5500:5500 -p 5501:5501 ghcr.io/jhalter/mobius:latest
-# Getting started
+You can now connect to localhost:5500 with your favorite Hotline client and play around, but all changes will be lost on container restart.
-### Mac OS
+To serve files from the host OS and persist configuration changes, you'll want to set up a [bind mount](https://docs.docker.com/storage/bind-mounts/) that maps a directory from the host into the container.
-For Mac OS the easiest path to installation is to install through Homebrew.
+To do this, create a directory in a location of your choice on the host OS. For clarity, we'll assign the path to the `HLFILES` environment variable and re-use it:
-#### Client
+```
+export HLFILES=/home/myuser/hotline-files
+mdkir $HLFILES
- brew install jhalter/mobius-hotline-client/mobius-hotline-client
+sudo docker run \
+ --pull=always \
+ --rm \
+ -p 5500:5500 \
+ -p 5501:5501 \
+ -v $HLFILES:/usr/local/var/mobius/config \
+ ghcr.io/jhalter/mobius:latest \
+ -init
+```
-After installation `mobius-hotline-client` installed to `/usr/local/bin/mobius-hotline-client` and should be in your $PATH.
+It's a good security practice to run your server as a non-root user, which also happens to make editing the configuration files easier from the host OS.
-The client config file is in `/usr/local/etc/mobius-client-config.yaml`
+To do this, add the `--user` flag to the docker run arguments with a user ID and group ID of a user on the host OS.
-Run `mobius-hotline-client -help` for usage options.
+`--user 1001:1001`
-#### Server
-
- brew install jhalter/mobius-hotline-client/mobius-hotline-client
+You'll now find a configuration directory on your host OS populated with a default configuration:
-After installation `mobius-hotline-server` installed to `/usr/local/bin/mobius-hotline-server` and should be in your $PATH.
+```
+❯ ls -al $HLFILES
+total 32
+drwxr-xr-x 8 jhalter staff 256 Jun 12 17:11 .
+drwxr-x---+ 49 jhalter staff 1568 Jun 12 17:11 ..
+-rw-r--r-- 1 jhalter staff 38 Jun 12 17:11 Agreement.txt
+drwxr-xr-x 3 jhalter staff 96 Jun 12 17:11 Files
+-rw-r--r-- 1 jhalter staff 19 Jun 12 17:11 MessageBoard.txt
+-rw-r--r-- 1 jhalter staff 15 Jun 12 17:11 ThreadedNews.yaml
+drwxr-xr-x 4 jhalter staff 128 Jun 12 17:11 Users
+-rw-r--r-- 1 jhalter staff 313 Jun 12 17:11 config.yaml
+```
-The server config file directory is under `/usr/local/var/mobius` which by default contains:
+Edit `config.yaml` to get started personalizing your server.
- /usr/local/var/mobius/config/MessageBoard.txt
- /usr/local/var/mobius/config/config.yaml
- /usr/local/var/mobius/config/ThreadedNews.yaml
- /usr/local/var/mobius/config/Agreement.txt
- /usr/local/var/mobius/config/Users/guest.yaml
- /usr/local/var/mobius/config/Users/admin.yaml
+### Mac OS
-Edit `/usr/local/var/mobius/config/config.yaml` to change your server name and other settings.
+For Mac OS the easiest path to installation is through Homebrew.
-Edit `/usr/local/var/mobius/config/Agreement.txt` to set your server agreement.
+#### Client
-Run `mobius-hotline-server -help` for usage options.
+To install the client:
-### Linux
+ brew install jhalter/mobius-hotline-client/mobius-hotline-client
-Download a compiled release for your architecture from the Releases page
+Then run `mobius-hotline-client` to get started.
-### Windows
+#### Server
- TODO
+To install the server:
+ brew install jhalter/mobius-hotline-server/mobius-hotline-server
-### Build from source
+After installation `mobius-hotline-server` will be installed at `$HOMEBREW_PREFIX/bin/mobius-hotline-server` and should be in your $PATH.
-To build from source, run:
+The server config file directory is under `$HOMEBREW_PREFIX/var/mobius` which by default contains:
- make build-client
- make build-server
+ /opt/homebrew/mobius/config/MessageBoard.txt
+ /opt/homebrew/var/mobius/config/config.yaml
+ /opt/homebrew/var/mobius/config/ThreadedNews.yaml
+ /opt/homebrew/var/mobius/config/Agreement.txt
+ /opt/homebrew/var/mobius/config/Users/guest.yaml
+ /opt/homebrew/var/mobius/config/Users/admin.yaml
-## Usage
+Edit `/usr/local/var/mobius/config/config.yaml` to change your server name and other settings.
-### Precompiled binaries
-To get started quickly, download the precompiled binaries for your platform:
+Edit `/usr/local/var/mobius/config/Agreement.txt` to set your server agreement.
-* [Linux]()
-* [Mac OS X]()
+Run `mobius-hotline-server -help` for usage options.
-## Compatibility
+### Linux
+Download a compiled release for your architecture from the Releases page or follow build from source instructions
+### Windows
-# TODO
+ TODO
-* Implement 1.5+ protocol account editing
-* Implement folder transfer resume
-* Implement file transfer queuing
-* Map additional file extensions to file type and creator codes
-* Implement file comment read/write
-* Implement user banning
-* Implement Maximum Simultaneous Downloads
-* Maximum simultaneous downloads/client
-* Maximum simultaneous connections/IP
-* Implement server broadcast
-* Implement statistics:
- * Currently Connected
- * Downloads in progress
- * Uploads in progress
- * Waiting Downloads
- * Connection Peak
- * Connection Counter
- * Download Counter
- * Upload Counter
- * Since
+### Build from source
+To build from source, run:
-# TODO - Someday Maybe
+ make all
-* Implement Pitbull protocol extensions
\ No newline at end of file
+Then grab your desired build from `dist`