diff --git a/README.md b/README.md index 32b189a..c0cac3e 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ lxc-iptag is a simple script to add ip tags to LXC containers. ## 1. Installation ```sh -curl -sL https://github.com/gitsang/lxc-iptag/raw/main/install.sh | sudo bash +curl -sL https://github.com/gitsang/lxc-iptag/raw/main/install.sh | bash ``` This script will: @@ -20,8 +20,8 @@ This script will: ### 1.1 Update ```sh -sudo curl -sSL https://raw.githubusercontent.com/gitsang/lxc-iptag/main/lxc-iptag -o /usr/local/bin/lxc-iptag && sudo chmod +x /usr/local/bin/lxc-iptag -sudo systemctl restart lxc-iptag.service +curl -sSL https://raw.githubusercontent.com/gitsang/lxc-iptag/main/lxc-iptag -o /usr/local/bin/lxc-iptag && chmod +x /usr/local/bin/lxc-iptag +systemctl restart lxc-iptag.service ``` This script will only update the `lxc-iptag` executable script diff --git a/install.sh b/install.sh index 16afcae..0afee18 100644 --- a/install.sh +++ b/install.sh @@ -3,7 +3,7 @@ set -xe # install prerequisites -sudo apt install -y ipcalc +apt install -y ipcalc # install lxc-iptag curl -sSL https://raw.githubusercontent.com/gitsang/lxc-iptag/main/lxc-iptag -o /usr/local/bin/lxc-iptag && chmod +x /usr/local/bin/lxc-iptag @@ -13,6 +13,6 @@ curl -sSL https://raw.githubusercontent.com/gitsang/lxc-iptag/main/lxc-iptag.con curl -sSL https://raw.githubusercontent.com/gitsang/lxc-iptag/main/lxc-iptag.service -o /lib/systemd/system/lxc-iptag.service # start lxc-iptag -sudo systemctl daemon-reload -sudo systemctl enable lxc-iptag.service -sudo systemctl start lxc-iptag.service +systemctl daemon-reload +systemctl enable lxc-iptag.service +systemctl start lxc-iptag.service