mirror of
https://github.com/aziascreations/BakaShrot.git
synced 2026-11-23 20:58:46 +01:00
Added headers, Added license, Added docker example, Cleared trash
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -19,6 +19,9 @@
|
||||
# DatabasePath = /var/lib/bakashrot/server.sqlite (relative paths are from
|
||||
# that folder too).
|
||||
#
|
||||
# Or with docker-compose.yml, next to this file, and its empty server.ini
|
||||
# to fill in.
|
||||
#
|
||||
# `docker stop` stops it cleanly (SIGTERM). Console commands (names, vacuum,
|
||||
# restart...): start it with -it, then `docker attach bakashrot`, and
|
||||
# detach with Ctrl+P, Ctrl+Q.
|
||||
|
||||
@@ -0,0 +1,38 @@
|
||||
# BakaShrot server, example compose file.
|
||||
#
|
||||
# Fill in server.ini next to this file first (a private key, topics, a
|
||||
# client section: it's empty, the server refuses to start as it is), then,
|
||||
# from this folder, with a login to the registry holding the PureBasic
|
||||
# images (see the Dockerfile):
|
||||
# docker compose up -d --build
|
||||
# docker compose logs bakashrot # its public key, for client.ini
|
||||
# docker compose down # stops it cleanly (SIGTERM)
|
||||
#
|
||||
# Console commands (names, vacuum, restart...): `docker attach bakashrot`,
|
||||
# detach with Ctrl+P, Ctrl+Q (not Ctrl+C: that stops it).
|
||||
#
|
||||
# The database lives in the bakashrot-data volume, kept by `down`
|
||||
# (`down -v` deletes it).
|
||||
|
||||
services:
|
||||
bakashrot:
|
||||
build:
|
||||
# The repository's root: the build needs Commons/, Includes/, Server/.
|
||||
context: ../..
|
||||
dockerfile: Docker/Server/Dockerfile
|
||||
image: bakashrot-server
|
||||
container_name: bakashrot
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
# server.ini's [BakaShrot.Server] Port.
|
||||
- "12345:12345"
|
||||
volumes:
|
||||
- ./server.ini:/etc/bakashrot/server.ini:ro
|
||||
- bakashrot-data:/var/lib/bakashrot
|
||||
# Only needed to type console commands with `docker attach bakashrot`.
|
||||
# The server runs fine without these two lines.
|
||||
stdin_open: true
|
||||
tty: true
|
||||
|
||||
volumes:
|
||||
bakashrot-data:
|
||||
@@ -0,0 +1,60 @@
|
||||
; ============================================================================
|
||||
; BakaShrot server config, for docker-compose.yml: empty, fill it in.
|
||||
;
|
||||
; Every option is documented in Server/Config/schema.ini (config.example.ini
|
||||
; in a release). Keys: BakaShrotGenerateKeyPairs.exe. Never commit a filled
|
||||
; in copy, it holds the server's private key.
|
||||
; ============================================================================
|
||||
|
||||
[BakaShrot]
|
||||
; This server's private key. Its public key, which clients need as
|
||||
; ServerPublicKey, is in the log when it starts (docker compose logs).
|
||||
PrivateKey =
|
||||
|
||||
; The node this server authenticates as when it links to peers.
|
||||
Node =
|
||||
|
||||
|
||||
[BakaShrot.Topics]
|
||||
; One topic name per line.
|
||||
; logs
|
||||
|
||||
|
||||
[BakaShrot.Retention]
|
||||
; topic = age (30d, 12h...), or nothing to keep everything forever.
|
||||
; logs = 30d
|
||||
|
||||
|
||||
[BakaShrot.Server]
|
||||
; Empty: every interface (127.0.0.1 can't be reached from outside the
|
||||
; container). The port must match docker-compose.yml's.
|
||||
Host =
|
||||
Port = 12345
|
||||
ReplicatingTopics =
|
||||
NetThreadPoolSize = 4
|
||||
; In the bakashrot-data volume.
|
||||
DatabasePath = /var/lib/bakashrot/server.sqlite
|
||||
MaxAttachmentSize = 1G
|
||||
Synchronous = FULL
|
||||
|
||||
|
||||
; One section per peer, see schema.ini.
|
||||
; [BakaShrot.Peer.other]
|
||||
; Host =
|
||||
; Port =
|
||||
; Node =
|
||||
; PublicKey =
|
||||
|
||||
|
||||
; One section per client allowed to connect.
|
||||
[BakaShrot.Client.example]
|
||||
; The client's public key (client.ini's PublicKey).
|
||||
PublicKeys =
|
||||
; The node it writes as (client.ini's Node must say the same).
|
||||
Node =
|
||||
; DefaultTopic = logs
|
||||
; PushTopics = logs
|
||||
; ReadTopics = *
|
||||
AllowRead = 1
|
||||
AllowWrite = 1
|
||||
AllowQuery = 0
|
||||
Reference in New Issue
Block a user