mirror of
https://github.com/basecamp/omarchy.git
synced 2026-02-17 15:25:37 +00:00
fix: ensure that ufw is enabled
This commit is contained in:
@@ -17,6 +17,9 @@ sudo ufw allow in proto udp from 172.16.0.0/12 to 172.17.0.1 port 53 comment 'al
|
|||||||
# Turn on the firewall
|
# Turn on the firewall
|
||||||
sudo ufw --force enable
|
sudo ufw --force enable
|
||||||
|
|
||||||
|
# Enable UFW systemd service to start on boot
|
||||||
|
sudo systemctl enable ufw
|
||||||
|
|
||||||
# Turn on Docker protections
|
# Turn on Docker protections
|
||||||
sudo ufw-docker install
|
sudo ufw-docker install
|
||||||
sudo ufw reload
|
sudo ufw reload
|
||||||
|
|||||||
13
migrations/1756911131.sh
Executable file
13
migrations/1756911131.sh
Executable file
@@ -0,0 +1,13 @@
|
|||||||
|
echo "Enable UFW systemd service for existing installations"
|
||||||
|
|
||||||
|
# Check if UFW is installed and configured but systemd service not enabled
|
||||||
|
if command -v ufw >/dev/null 2>&1; then
|
||||||
|
# Check if UFW has rules configured (indicating it was set up by Omarchy)
|
||||||
|
if sudo ufw status | grep -q "Status: active\|22/tcp\|53317"; then
|
||||||
|
# Enable UFW systemd service if not already enabled
|
||||||
|
if ! systemctl is-enabled ufw >/dev/null 2>&1; then
|
||||||
|
sudo systemctl enable ufw
|
||||||
|
echo "UFW systemd service enabled"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
Reference in New Issue
Block a user