Docker + docker compose support

This commit is contained in:
Thomas Sileo 2022-07-18 20:44:55 +02:00
parent 3e7ad917e2
commit fe88481431
10 changed files with 141 additions and 29 deletions

View file

@ -1,6 +1,5 @@
import os
import secrets
import subprocess
from pathlib import Path
import bcrypt
@ -19,11 +18,13 @@ ROOT_DIR = Path().parent.resolve()
_CONFIG_FILE = os.getenv("MICROBLOGPUB_CONFIG_FILE", "profile.toml")
VERSION_COMMIT = (
subprocess.check_output(["git", "rev-parse", "--short=8", "HEAD"])
.split()[0]
.decode()
)
VERSION_COMMIT = "dev"
try:
from app._version import VERSION_COMMIT # type: ignore
except ImportError:
pass
VERSION = f"2.0.0+{VERSION_COMMIT}"
USER_AGENT = f"microblogpub/{VERSION}"