mirror of
https://github.com/dominikhoebert/docker-projects.git
synced 2026-06-11 14:26:17 +00:00
Füge Konfigurationsdateien für Gatus, Mosquitto, Postgres und MeshDash hinzu; aktualisiere Moodle-Umgebungsvariablen und erstelle Webstack-Dokumentation
This commit is contained in:
4
.gitignore
vendored
4
.gitignore
vendored
@@ -81,3 +81,7 @@ backrest/backup/
|
|||||||
backrest/repos/
|
backrest/repos/
|
||||||
semaphore/semaphore_config/config.json
|
semaphore/semaphore_config/config.json
|
||||||
semaphore/semaphore_data/database.boltdb
|
semaphore/semaphore_data/database.boltdb
|
||||||
|
mosquitto/data/
|
||||||
|
mosquitto/log/
|
||||||
|
mosquitto/config/
|
||||||
|
postgres17/postgres/
|
||||||
|
|||||||
21
gatus/compose.yml
Normal file
21
gatus/compose.yml
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
# https://github.com/TwiN/gatus/blob/master/.examples/docker-compose/docker-compose.yml
|
||||||
|
|
||||||
|
#
|
||||||
|
|
||||||
|
name: gatus
|
||||||
|
|
||||||
|
services:
|
||||||
|
gatus:
|
||||||
|
image: twinproduction/gatus:latest
|
||||||
|
container_name: gatus
|
||||||
|
ports:
|
||||||
|
- 8080:8080
|
||||||
|
volumes:
|
||||||
|
- ./config:/config
|
||||||
|
networks:
|
||||||
|
- proxy
|
||||||
|
|
||||||
|
networks:
|
||||||
|
proxy:
|
||||||
|
external: true
|
||||||
|
|
||||||
40
gatus/config/config.yaml
Normal file
40
gatus/config/config.yaml
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
|
||||||
|
|
||||||
|
ui:
|
||||||
|
default-sort-by: group
|
||||||
|
|
||||||
|
connectivity:
|
||||||
|
checker:
|
||||||
|
target: 1.1.1.1:53
|
||||||
|
interval: 60s
|
||||||
|
|
||||||
|
endpoints:
|
||||||
|
- name: website # Name of your endpoint, can be anything
|
||||||
|
group: Test
|
||||||
|
url: "https://twin.sh/health"
|
||||||
|
interval: 5m # Duration to wait between every status check (default: 60s)
|
||||||
|
conditions:
|
||||||
|
- "[STATUS] == 200" # Status must be 200
|
||||||
|
- "[BODY].status == UP" # The json path "$.status" must be equal to UP
|
||||||
|
- "[RESPONSE_TIME] < 300" # Response time must be under 300ms
|
||||||
|
alerts:
|
||||||
|
- type: telegram
|
||||||
|
|
||||||
|
- name: make-sure-header-is-rendered
|
||||||
|
group: Test
|
||||||
|
url: "https://example.org/"
|
||||||
|
interval: 60s
|
||||||
|
conditions:
|
||||||
|
- "[STATUS] == 200" # Status must be 200
|
||||||
|
- "[BODY] == pat(*<h1>Example Domain</h1>*)" # Body must contain the specified header
|
||||||
|
alerts:
|
||||||
|
- type: telegram
|
||||||
|
|
||||||
|
- name: Guacamole
|
||||||
|
group: Local
|
||||||
|
url: "http://host.docker.internal:80"
|
||||||
|
conditions:
|
||||||
|
- "[STATUS] == 200"
|
||||||
|
alerts:
|
||||||
|
- type: telegram
|
||||||
|
|
||||||
BIN
mariadb/.DS_Store
vendored
Normal file
BIN
mariadb/.DS_Store
vendored
Normal file
Binary file not shown.
@@ -9,11 +9,9 @@ services:
|
|||||||
container_name: mariadb
|
container_name: mariadb
|
||||||
restart: always
|
restart: always
|
||||||
ports:
|
ports:
|
||||||
- 3306:3306
|
- 127.0.0.1:3306:3306
|
||||||
environment:
|
environment:
|
||||||
MARIADB_ROOT_PASSWORD: example
|
MARIADB_ROOT_PASSWORD: administrator
|
||||||
MARIADB_USER: example-user
|
|
||||||
MARIADB_PASSWORD: my_cool_secret
|
|
||||||
volumes:
|
volumes:
|
||||||
- ./mysql:/var/lib/mysql
|
- ./mysql:/var/lib/mysql
|
||||||
|
|
||||||
@@ -60,14 +58,14 @@ services:
|
|||||||
LABEL_con1: MariaDB
|
LABEL_con1: MariaDB
|
||||||
SERVER_con1: mariadb
|
SERVER_con1: mariadb
|
||||||
USER_con1: root
|
USER_con1: root
|
||||||
PASSWORD_con1: example
|
PASSWORD_con1: administrator
|
||||||
PORT_con1: 3306
|
PORT_con1: 3306
|
||||||
ENGINE_con1: mysql@dbgate-plugin-mysql
|
ENGINE_con1: mysql@dbgate-plugin-mysql
|
||||||
|
|
||||||
nocodb:
|
nocodb:
|
||||||
container_name: nocodb
|
container_name: nocodb
|
||||||
# environment:
|
# environment:
|
||||||
# NC_DB: "mysql://mariadb:3306?u=root&p=example"
|
# NC_DB: "mysql://mariadb:3306?u=root&p=administrator"
|
||||||
image: "nocodb/nocodb:latest"
|
image: "nocodb/nocodb:latest"
|
||||||
ports:
|
ports:
|
||||||
- "8070:8080"
|
- "8070:8080"
|
||||||
|
|||||||
16
meshdash/compose.yml
Normal file
16
meshdash/compose.yml
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
services:
|
||||||
|
meshdash:
|
||||||
|
image: rusjpmd/meshdash-runner:latest
|
||||||
|
container_name: meshdash
|
||||||
|
restart: always
|
||||||
|
network_mode: host
|
||||||
|
privileged: true
|
||||||
|
environment:
|
||||||
|
MD_SETUP_KEY: "YOUR_API_KEY_HERE"
|
||||||
|
MD_SETUP_URL: "https://meshdash.co.uk/user_setup_core.php"
|
||||||
|
volumes:
|
||||||
|
- /dev:/dev
|
||||||
|
- meshdash_data:/app/data
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
meshdash_data:
|
||||||
12
moodle/.env
Normal file
12
moodle/.env
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
# Moodle application admin credentials
|
||||||
|
MOODLE_USERNAME=admin
|
||||||
|
MOODLE_PASSWORD=change_me_admin_password
|
||||||
|
MOODLE_EMAIL=admin@example.com
|
||||||
|
|
||||||
|
# Database connection details
|
||||||
|
MOODLE_DATABASE_USER=moodle
|
||||||
|
MOODLE_DATABASE_PASSWORD=change_me_database_password
|
||||||
|
MOODLE_DATABASE_NAME=moodle
|
||||||
|
|
||||||
|
# MariaDB root credentials
|
||||||
|
MARIADB_ROOT_PASSWORD=change_me_root_password
|
||||||
11
mosquitto/compose.yml
Normal file
11
mosquitto/compose.yml
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
services:
|
||||||
|
mosquitto:
|
||||||
|
image: eclipse-mosquitto:2
|
||||||
|
container_name: mosquitto
|
||||||
|
restart: unless-stopped
|
||||||
|
ports:
|
||||||
|
- "1883:1883"
|
||||||
|
volumes:
|
||||||
|
- ./config/mosquitto.conf:/mosquitto/config/mosquitto.conf:ro
|
||||||
|
- ./data:/mosquitto/data
|
||||||
|
- ./log:/mosquitto/log
|
||||||
31
postgres17/compose.yml
Normal file
31
postgres17/compose.yml
Normal file
@@ -0,0 +1,31 @@
|
|||||||
|
name: postgres
|
||||||
|
|
||||||
|
services:
|
||||||
|
postgres:
|
||||||
|
container_name: postgres
|
||||||
|
image: postgres:17.6
|
||||||
|
restart: unless-stopped
|
||||||
|
ports:
|
||||||
|
- 5432:5432
|
||||||
|
environment:
|
||||||
|
POSTGRES_PASSWORD: postgres
|
||||||
|
POSTGRES_USER: postgres
|
||||||
|
volumes:
|
||||||
|
- ./postgres:/var/lib/postgresql/data
|
||||||
|
|
||||||
|
pgadmin:
|
||||||
|
container_name: pgadmin
|
||||||
|
image: dpage/pgadmin4:2025-09-02-1
|
||||||
|
environment:
|
||||||
|
PGADMIN_DEFAULT_EMAIL: admin@pgadmin.com
|
||||||
|
PGADMIN_DEFAULT_PASSWORD: password
|
||||||
|
PGADMIN_LISTEN_PORT: 80
|
||||||
|
ports:
|
||||||
|
- 15433:80
|
||||||
|
volumes:
|
||||||
|
- pgadmin:/var/lib/pgadmin
|
||||||
|
depends_on:
|
||||||
|
- postgres
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
pgadmin:
|
||||||
13
webstack-task/TASK.md
Normal file
13
webstack-task/TASK.md
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
Es soll ein Webstack lokal mit Docker aufgesetzt werden.
|
||||||
|
|
||||||
|
1. [nginx](https://hub.docker.com/_/nginx)
|
||||||
|
2. [PHP](https://hub.docker.com/_/php)
|
||||||
|
3. [sftp](https://hub.docker.com/r/atmoz/sftp)
|
||||||
|
|
||||||
|
sftp um die Dateien zu übertragen und verwalten. nginx und PHP als Webserver.
|
||||||
|
Hoste eine einfache Testanwendung auf dem Server.
|
||||||
|
Verwende Docker Compose.
|
||||||
|
|
||||||
|
Die Lehrperson soll mit deiner IP-Adresse darauf zugreifen können.
|
||||||
|
|
||||||
|
Dokumentiere die Schritte hier kurz, und lade sie hoch.
|
||||||
13
webstack-task/app/index.html
Normal file
13
webstack-task/app/index.html
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
<!doctype html>
|
||||||
|
<html lang="de">
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8" />
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||||
|
<title>Webstack Task</title>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<h1>Webstack Task</h1>
|
||||||
|
<p>Wenn du das siehst, liefert Nginx aus.</p>
|
||||||
|
<p><a href="/index.php">PHP-Test öffnen</a></p>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
9
webstack-task/app/index.php
Normal file
9
webstack-task/app/index.php
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
declare(strict_types=1);
|
||||||
|
|
||||||
|
header('Content-Type: text/plain; charset=utf-8');
|
||||||
|
|
||||||
|
echo "Webstack läuft.\n";
|
||||||
|
echo "Zeit (Server): " . date('c') . "\n";
|
||||||
|
echo "PHP-Version: " . PHP_VERSION . "\n";
|
||||||
39
webstack-task/compose.yml
Normal file
39
webstack-task/compose.yml
Normal file
@@ -0,0 +1,39 @@
|
|||||||
|
services:
|
||||||
|
nginx:
|
||||||
|
image: nginx:1.27-alpine
|
||||||
|
container_name: webstack-nginx
|
||||||
|
depends_on:
|
||||||
|
- php
|
||||||
|
ports:
|
||||||
|
- "${WEBSTACK_HTTP_PORT:-8080}:80"
|
||||||
|
volumes:
|
||||||
|
- ./app:/var/www/html:ro
|
||||||
|
- ./nginx/default.conf:/etc/nginx/conf.d/default.conf:ro
|
||||||
|
networks:
|
||||||
|
- webstack
|
||||||
|
restart: unless-stopped
|
||||||
|
|
||||||
|
php:
|
||||||
|
image: php:8.3-fpm-alpine
|
||||||
|
container_name: webstack-php
|
||||||
|
volumes:
|
||||||
|
- ./app:/var/www/html:ro
|
||||||
|
networks:
|
||||||
|
- webstack
|
||||||
|
restart: unless-stopped
|
||||||
|
|
||||||
|
sftp:
|
||||||
|
image: atmoz/sftp:alpine
|
||||||
|
container_name: webstack-sftp
|
||||||
|
platform: linux/amd64
|
||||||
|
ports:
|
||||||
|
- "${WEBSTACK_SFTP_PORT:-2222}:22"
|
||||||
|
volumes:
|
||||||
|
- ./app:/home/webuser/upload
|
||||||
|
command: "webuser:webpass:1000:1000:upload"
|
||||||
|
networks:
|
||||||
|
- webstack
|
||||||
|
restart: unless-stopped
|
||||||
|
|
||||||
|
networks:
|
||||||
|
webstack: {}
|
||||||
22
webstack-task/nginx/default.conf
Normal file
22
webstack-task/nginx/default.conf
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
server {
|
||||||
|
listen 80;
|
||||||
|
server_name _;
|
||||||
|
|
||||||
|
root /var/www/html;
|
||||||
|
index index.php index.html;
|
||||||
|
|
||||||
|
location / {
|
||||||
|
try_files $uri $uri/ /index.php?$query_string;
|
||||||
|
}
|
||||||
|
|
||||||
|
location ~ \.php$ {
|
||||||
|
include fastcgi_params;
|
||||||
|
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
||||||
|
fastcgi_param DOCUMENT_ROOT $document_root;
|
||||||
|
fastcgi_pass php:9000;
|
||||||
|
}
|
||||||
|
|
||||||
|
location ~ /\.ht {
|
||||||
|
deny all;
|
||||||
|
}
|
||||||
|
}
|
||||||
30
windows/compose.yml
Normal file
30
windows/compose.yml
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
#
|
||||||
|
|
||||||
|
# https://github.com/dockur/windows
|
||||||
|
|
||||||
|
name: windows
|
||||||
|
|
||||||
|
services:
|
||||||
|
windows:
|
||||||
|
image: dockurr/windows
|
||||||
|
container_name: windows
|
||||||
|
environment:
|
||||||
|
VERSION: "11"
|
||||||
|
RAM_SIZE: "8G"
|
||||||
|
CPU_CORES: "4"
|
||||||
|
KVM: "N"
|
||||||
|
# devices:
|
||||||
|
# - /dev/kvm
|
||||||
|
# - /dev/net/tun
|
||||||
|
cap_add:
|
||||||
|
- NET_ADMIN
|
||||||
|
ports:
|
||||||
|
- 8006:8006
|
||||||
|
- 3389:3389/tcp
|
||||||
|
- 3389:3389/udp
|
||||||
|
volumes:
|
||||||
|
- ./windows:/storage
|
||||||
|
restart: always
|
||||||
|
stop_grace_period: 2m
|
||||||
|
|
||||||
|
|
||||||
Reference in New Issue
Block a user