Attempting to correct for Tomcat on port 8082

This commit is contained in:
Marwolf
2018-08-04 00:00:43 -04:00
parent 418cedafe4
commit e5c7f34d26
2 changed files with 8 additions and 6 deletions

View File

@@ -99,7 +99,7 @@ if [ "$install" == "1" ]; then
echo "" echo ""
echo "Configuring UFW to allow good ports and block MySQL from outside" echo "Configuring UFW to allow good ports and block MySQL from outside"
echo "" echo ""
sudo ufw allow 22/tcp && ufw allow 80/tcp && ufw allow 443/tcp && ufw allow 80/tcp && ufw allow 53595/tcp && ufw deny 3306/tcp sudo ufw allow 22/tcp && ufw allow 80/tcp && ufw allow 8082/tcp && ufw allow 443/tcp && ufw allow 80/tcp && ufw allow 53595/tcp && ufw deny 3306/tcp
sudo sed -i 's/DEFAULT_FORWARD_POLICY="DENY"/DEFAULT_FORWARD_POLICY="ACCEPT"/g' /etc/default/ufw sudo sed -i 's/DEFAULT_FORWARD_POLICY="DENY"/DEFAULT_FORWARD_POLICY="ACCEPT"/g' /etc/default/ufw
sudo ufw reload sudo ufw reload
echo "" echo ""
@@ -138,6 +138,7 @@ if [ "$install" == "1" ]; then
echo "Permitting good ports through the firewall." echo "Permitting good ports through the firewall."
echo "" echo ""
firewall-cmd --permanent --add-port=53595/tcp firewall-cmd --permanent --add-port=53595/tcp
firewall-cmd --permanent --add-port=8082/tcp
firewall-cmd --permanent --add-port=80/tcp firewall-cmd --permanent --add-port=80/tcp
firewall-cmd --permanent --add-port=443/tcp firewall-cmd --permanent --add-port=443/tcp
firewall-cmd --permanent --add-port=22/tcp firewall-cmd --permanent --add-port=22/tcp
@@ -219,9 +220,12 @@ if [ "$install" == "1" ]; then
sudo systemctl enable fail2ban sudo systemctl enable fail2ban
echo "" echo ""
echo "" echo ""
echo "Permitting default game port 53595/tcp through the firewall." echo "Permitting ports through the firewall."
firewall-cmd --permanent --add-port=53595/tcp firewall-cmd --permanent --add-port=53595/tcp
echo "" firewall-cmd --permanent --add-port=8082/tcp
firewall-cmd --permanent --add-port=80/tcp
firewall-cmd --permanent --add-port=443/tcp
firewall-cmd --permanent --add-port=22/tcp
firewall-cmd --reload firewall-cmd --reload
echo "" echo ""
echo "" echo ""

View File

@@ -78,13 +78,11 @@ services:
image: tomcat:9.0.10-jre10-slim image: tomcat:9.0.10-jre10-slim
container_name: tomcat container_name: tomcat
ports: ports:
- "8082:8082" - "0.0.0.0:8082:8082"
restart: always restart: always
volumes: volumes:
- "./Website:/usr/local/tomcat/webapps/ROOT" - "./Website:/usr/local/tomcat/webapps/ROOT"
- "./etc/tomcat:/usr/local/tomcat/conf" - "./etc/tomcat:/usr/local/tomcat/conf"
depends_on:
- mysqldb
# logging: # logging:
# driver: splunk # driver: splunk
# options: # options: