This commit is contained in:
docker 2025-12-31 07:32:10 +00:00
parent 0dcdfa9a7b
commit 8ce0a1caf8
4 changed files with 32 additions and 6 deletions

27
.gitignore vendored
View File

@ -1,3 +1,30 @@
mariadb/ mariadb/
!mariadb/.gitkeep !mariadb/.gitkeep
.env .env
docker-data/dms/mail-data/
docker-data/dms/mail-state/
docker-data/dms/mail-logs/
osTicket-v1.18.2/include/ost-config.php
osTicket-v1.18.2/upload/
*.log
logs/
# Development artifacts
*.save
*.swp
*~
notes.txt
my-httpd.conf
# OS files
.DS_Store
Thumbs.db
# IDE
.vscode/
.idea/
*.iml

View File

@ -59,10 +59,9 @@ services:
- SSL_TYPE=manual - SSL_TYPE=manual
- SSL_CERT_PATH=${SSL_CERT_PATH} - SSL_CERT_PATH=${SSL_CERT_PATH}
- SSL_KEY_PATH=${SSL_KEY_PATH} - SSL_KEY_PATH=${SSL_KEY_PATH}
- POSTFIX_MASTER_CF_OVERRIDES=/tmp/docker-mailserver/postfix-master.cf
- POSTFIX_VIRTUAL_TRANSPORT=/tmp/docker-mailserver/postfix-virtual.cf
- OSTICKET_API_KEY=${OSTICKET_API_KEY} - OSTICKET_API_KEY=${OSTICKET_API_KEY}
- OSTICKET_URL=http://${APACHE_IP}/api/tickets.email - OSTICKET_URL=http://${APACHE_IP}/api/tickets.email
- SUPPORT_EMAIL=support@${MAIL_DOMAIN}
cap_add: cap_add:
- NET_ADMIN # For Fail2Ban to work - NET_ADMIN # For Fail2Ban to work
restart: unless-stopped restart: unless-stopped

View File

@ -13,7 +13,7 @@ grep -q "osticket-pipe" /etc/postfix/master.cf || \
echo "osticket-pipe unix - n n - - pipe flags=DRhu user=docker:docker argv=/tmp/docker-mailserver/scripts/pipe-to-osticket.sh" >> /etc/postfix/master.cf echo "osticket-pipe unix - n n - - pipe flags=DRhu user=docker:docker argv=/tmp/docker-mailserver/scripts/pipe-to-osticket.sh" >> /etc/postfix/master.cf
# Create transport map # Create transport map
echo "support@matthu.net osticket-pipe:" > /etc/postfix/transport SUPPORT_EMAIL="${SUPPORT_EMAIL:-support@matthu.net}"
# Configure Postfix to use transport map # Configure Postfix to use transport map
postconf -e "transport_maps = hash:/etc/postfix/transport" postconf -e "transport_maps = hash:/etc/postfix/transport"
@ -22,7 +22,7 @@ postconf -e "transport_maps = hash:/etc/postfix/transport"
postmap /etc/postfix/transport postmap /etc/postfix/transport
# Remove from virtual alias if present # Remove from virtual alias if present
sed -i '/support@matthu.net/d' /etc/postfix/virtual 2>/dev/null || true sed -i '/${SUPPORT_EMAIL}/d' /etc/postfix/virtual 2>/dev/null || true
postmap /etc/postfix/virtual 2>/dev/null || true postmap /etc/postfix/virtual 2>/dev/null || true
# Reload postfix # Reload postfix

View File

@ -1,7 +1,7 @@
#/bin/sh #!/bin/sh
rm osTicket-v1.18.2/include/ost-config.php rm osTicket-v1.18.2/include/ost-config.php
cp osTicket-v1.18.2/include/ost-sampleconfig.php osTicket-v1.18.2/include/ost-config.php cp osTicket-v1.18.2/include/ost-sampleconfig.php osTicket-v1.18.2/include/ost-config.php
chomd 0666 osTicket-v1.18.2/include/ost-config.php chmod 0666 osTicket-v1.18.2/include/ost-config.php
rm -Rf mariadb/* rm -Rf mariadb/*
rm mariadb/.my-healthcheck.cnf rm mariadb/.my-healthcheck.cnf