cockpit env
This commit is contained in:
@@ -166,7 +166,7 @@ services:
|
|||||||
- DNSCRYPT_LISTEN_PORT=5054
|
- DNSCRYPT_LISTEN_PORT=5054
|
||||||
# resolvers: https://download.dnscrypt.info/dnscrypt-resolvers/v2/public-resolvers.md
|
# resolvers: https://download.dnscrypt.info/dnscrypt-resolvers/v2/public-resolvers.md
|
||||||
#- DNSCRYPT_SERVER_NAMES=['scaleway-fr','google','yandex','cloudflare']
|
#- DNSCRYPT_SERVER_NAMES=['scaleway-fr','google','yandex','cloudflare']
|
||||||
- DNSCRYPT_SERVER_NAMES=['cloudflare','dnswarden-doh1','dnswarden-doh2','dnswarden-doh3','securedns-doh','adguard-dns-doh']
|
- DNSCRYPT_SERVER_NAMES=['cloudflare','dnswarden-doh1','dnswarden-doh2','dnswarden-doh3','adguard-dns-doh']
|
||||||
networks:
|
networks:
|
||||||
pihole_net:
|
pihole_net:
|
||||||
ipv4_address: 10.2.0.2
|
ipv4_address: 10.2.0.2
|
||||||
|
|||||||
@@ -150,6 +150,9 @@ if [[ "$MISTBORN_INSTALL_COCKPIT" =~ ^([yY][eE][sS]|[yY])$ ]]
|
|||||||
then
|
then
|
||||||
# install cockpit
|
# install cockpit
|
||||||
source ./scripts/subinstallers/cockpit.sh
|
source ./scripts/subinstallers/cockpit.sh
|
||||||
|
|
||||||
|
# set variable (that will be available in environment)
|
||||||
|
MISTBORN_INSTALL_COCKPIT=Y
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Mistborn-cli (pip3 installed by docker)
|
# Mistborn-cli (pip3 installed by docker)
|
||||||
|
|||||||
@@ -14,13 +14,13 @@ ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/base.yml down
|
|||||||
|
|
||||||
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/base.yml build
|
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/base.yml build
|
||||||
ExecStartPre=-/sbin/ip address add 10.2.3.1/30 dev DIFACE
|
ExecStartPre=-/sbin/ip address add 10.2.3.1/30 dev DIFACE
|
||||||
ExecStartPre=/sbin/iptables -w 300 -I DOCKER-USER -i DIFACE -p udp --dport 53 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p udp --dport 53 -j MISTBORN_LOG_DROP
|
||||||
ExecStartPre=/sbin/iptables -I DOCKER-USER -i DIFACE -p tcp --dport 53 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p tcp --dport 53 -j MISTBORN_LOG_DROP
|
||||||
ExecStartPre=/sbin/iptables -I DOCKER-USER -i DIFACE -p tcp --dport 80 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p tcp --dport 80 -j MISTBORN_LOG_DROP
|
||||||
ExecStartPre=/sbin/iptables -I DOCKER-USER -i DIFACE -p tcp --dport 443 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p tcp --dport 443 -j MISTBORN_LOG_DROP
|
||||||
ExecStartPre=/sbin/iptables -I DOCKER-USER -i DIFACE -p tcp --dport 5555 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p tcp --dport 5555 -j MISTBORN_LOG_DROP
|
||||||
ExecStartPre=/sbin/iptables -A OUTPUT -o DIFACE -p udp --dport 53 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -A OUTPUT -o DIFACE -p udp --dport 53 -j MISTBORN_LOG_DROP
|
||||||
ExecStartPre=/sbin/ip6tables -A OUTPUT -p udp --dport 53 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/ip6tables -w -A OUTPUT -p udp --dport 53 -j MISTBORN_LOG_DROP
|
||||||
ExecStartPre=/sbin/resolvconf -u
|
ExecStartPre=/sbin/resolvconf -u
|
||||||
# Start container when unit is started
|
# Start container when unit is started
|
||||||
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/base.yml up
|
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/base.yml up
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ PermissionsStartOnly=true
|
|||||||
# Shutdown container (if running) when unit is stopped
|
# Shutdown container (if running) when unit is stopped
|
||||||
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/extra/bitwarden.yml down
|
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/extra/bitwarden.yml down
|
||||||
|
|
||||||
ExecStartPre=/sbin/iptables -w 300 -I DOCKER-USER -i DIFACE -p tcp --dport 3012 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p tcp --dport 3012 -j MISTBORN_LOG_DROP
|
||||||
# Start container when unit is started
|
# Start container when unit is started
|
||||||
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/extra/bitwarden.yml up --build
|
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/extra/bitwarden.yml up --build
|
||||||
# Stop container when unit is stopped
|
# Stop container when unit is stopped
|
||||||
|
|||||||
@@ -13,8 +13,8 @@ EnvironmentFile=/opt/mistborn/.envs/.production/.jitsi
|
|||||||
# Shutdown container (if running) when unit is stopped
|
# Shutdown container (if running) when unit is stopped
|
||||||
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/extra/jitsi-meet.yml down
|
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/extra/jitsi-meet.yml down
|
||||||
|
|
||||||
ExecStartPre=/sbin/iptables -w 300 -I DOCKER-USER -i DIFACE -p udp --dport $JVB_PORT -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p udp --dport $JVB_PORT -j MISTBORN_LOG_DROP
|
||||||
ExecStartPre=/sbin/iptables -I DOCKER-USER -i DIFACE -p tcp --dport $JVB_TCP_PORT -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p tcp --dport $JVB_TCP_PORT -j MISTBORN_LOG_DROP
|
||||||
# Start container when unit is started
|
# Start container when unit is started
|
||||||
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/extra/jitsi-meet.yml up --build
|
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/extra/jitsi-meet.yml up --build
|
||||||
# Stop container when unit is stopped
|
# Stop container when unit is stopped
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ PermissionsStartOnly=true
|
|||||||
# Shutdown container (if running) when unit is stopped
|
# Shutdown container (if running) when unit is stopped
|
||||||
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/extra/rocketchat.yml down
|
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/extra/rocketchat.yml down
|
||||||
|
|
||||||
ExecStartPre=/sbin/iptables -w 300 -I DOCKER-USER -i DIFACE -p tcp --dport 3001 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p tcp --dport 3001 -j MISTBORN_LOG_DROP
|
||||||
# Start container when unit is started
|
# Start container when unit is started
|
||||||
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/extra/rocketchat.yml up --build
|
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/extra/rocketchat.yml up --build
|
||||||
# Stop container when unit is stopped
|
# Stop container when unit is stopped
|
||||||
|
|||||||
@@ -11,8 +11,8 @@ PermissionsStartOnly=true
|
|||||||
# Shutdown container (if running) when unit is stopped
|
# Shutdown container (if running) when unit is stopped
|
||||||
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/extra/syncthing.yml down
|
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/extra/syncthing.yml down
|
||||||
|
|
||||||
ExecStartPre=/sbin/iptables -w 300 -I DOCKER-USER -i DIFACE -p udp --dport 21027 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p udp --dport 21027 -j MISTBORN_LOG_DROP
|
||||||
ExecStartPre=/sbin/iptables -I DOCKER-USER -i DIFACE -p tcp --dport 22000 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p tcp --dport 22000 -j MISTBORN_LOG_DROP
|
||||||
# Start container when unit is started
|
# Start container when unit is started
|
||||||
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/extra/syncthing.yml up --build
|
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/extra/syncthing.yml up --build
|
||||||
# Stop container when unit is stopped
|
# Stop container when unit is stopped
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ PermissionsStartOnly=true
|
|||||||
# Shutdown container (if running) when unit is stopped
|
# Shutdown container (if running) when unit is stopped
|
||||||
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/extra/tor.yml down
|
ExecStartPre=/usr/local/bin/docker-compose -f /opt/mistborn/extra/tor.yml down
|
||||||
|
|
||||||
ExecStartPre=/sbin/iptables -w 300 -I DOCKER-USER -i DIFACE -p tcp --dport 9150 -j MISTBORN_LOG_DROP
|
ExecStartPre=/sbin/iptables -w -I DOCKER-USER -i DIFACE -p tcp --dport 9150 -j MISTBORN_LOG_DROP
|
||||||
# Start container when unit is started
|
# Start container when unit is started
|
||||||
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/extra/tor.yml up --build
|
ExecStart=/usr/local/bin/docker-compose -f /opt/mistborn/extra/tor.yml up --build
|
||||||
# Stop container when unit is stopped
|
# Stop container when unit is stopped
|
||||||
|
|||||||
@@ -19,6 +19,7 @@ echo "MISTBORN_DEFAULT_PASSWORD=$MISTBORN_DEFAULT_PASSWORD" >> $DJANGO_PROD_FILE
|
|||||||
echo "#MAILGUN_API_KEY=" >> $DJANGO_PROD_FILE
|
echo "#MAILGUN_API_KEY=" >> $DJANGO_PROD_FILE
|
||||||
echo "#MAILGUN_API_URL=" >> $DJANGO_PROD_FILE
|
echo "#MAILGUN_API_URL=" >> $DJANGO_PROD_FILE
|
||||||
echo "#SENTRY_DNS=" >> $DJANGO_PROD_FILE
|
echo "#SENTRY_DNS=" >> $DJANGO_PROD_FILE
|
||||||
|
echo "MISTBORN_INSTALL_COCKPIT=$MISTBORN_INSTALL_COCKPIT" >> $DJANGO_PROD_FILE
|
||||||
|
|
||||||
# generate production .env file for postgresql
|
# generate production .env file for postgresql
|
||||||
POSTGRES_PROD_FILE="./.envs/.production/.postgres"
|
POSTGRES_PROD_FILE="./.envs/.production/.postgres"
|
||||||
|
|||||||
Reference in New Issue
Block a user