adamcooke/staytus as a Container Image without the MySQL server.
Image available from:
- Quay.io
- GHCR.io
- DEPRECATED Docker Hub
- Docker Hub has been deprecated as of 18.09.2021!
Container Image Tags:
main- Latest build of themainbranch.vx.y.z- Latest build of the application (updated in-sync with the date container image tags).vx.y.z-YYYYmmdd-HHMMSS-NNN- Latest build of the application with date of the build.
From Quay.io:
docker pull quay.io/galexrt/staytus:mainOr from GHCR.io:
docker pull ghcr.io/galexrt/staytus:mainFor the Docker Staytus image to work, you'll need to start a MySQL server (or container). The commands below creates a network, start a MariaDB and then starts the Staytus container.
Create the separate network for Staytus and database:
docker network create staytusStart the MariaDB database container:
docker run \
-d \
--name=database \
--net=staytus \
-e MYSQL_ROOT_PASSWORD=my-secret-pw \
-e MYSQL_DATABASE=staytus \
-e MYSQL_USER=staytus \
-e MYSQL_PASSWORD=staytus \
mariadb:10.4.4-bionicStart the Staytus container with the environment variables pointing to the created database container.
docker run \
-d \
--name=staytus \
--net=staytus \
-p 8787:8787 \
-e 'DB_HOST=database' \
-e 'DB_USER=staytus' \
-e 'DB_PASSWORD=staytus' \
quay.io/galexrt/staytus:mainAfter running the commands, open 127.0.0.1:8787, YOUR_IP:8787 (or the server IP when Docker is running on a server) in your browser to run the setup for your containerized Staytus instance.
If you want to manually configure Staytus, you can point a volume to /opt/staytus/staytus/config/ and put the database.yaml config in that volume yourself.
docker run \
[...]
-e 'AUTO_CONF=false' \
-v /opt/docker/staytus/config:/opt/staytus/staytus/config:ro \
[...]
quay.io/galexrt/staytus:lastestNOTE
TL;DR Create a database with
CHARSET utf8mb4andCOLLATE utf8mb4_unicode_ci.Database setup instructions here https://github.com/adamcooke/staytus#instructions
You can add the following variables as env vars to your Docker run command:
AUTO_CONF(Default:true) - Enable or disable thedatabase.yamlconfiguration, based on the upcomingDB_*variables.DB_ADAPTER(Default:mysql2)DB_POOL(Default:5)DB_HOST(Default:database)DB_DATABASE(Default:staytus)DB_USER(Default:staytus)DB_PASSWORD(Default: empty)
You can add the following variables as env vars to your Docker run command:
STAYTUS_SMTP_HOSTNAMESTAYTUS_SMTP_USERNAMESTAYTUS_SMTP_PASSWORD