mirror of
https://github.com/edoardoColi/Communication_Sandbox.git
synced 2026-10-16 10:52:11 +00:00
smal fix, update and gitignore
This commit is contained in:
@@ -0,0 +1,3 @@
|
|||||||
|
# Local Codex/agent workspace files
|
||||||
|
.agents/
|
||||||
|
.codex/
|
||||||
@@ -14,7 +14,7 @@ class MyRouter (Node):
|
|||||||
self.cmd('sysctl net.ipv4.ip_forward=1') #Enable forwarding on the router
|
self.cmd('sysctl net.ipv4.ip_forward=1') #Enable forwarding on the router
|
||||||
def terminate(self):
|
def terminate(self):
|
||||||
self.cmd('sysctl net.ipv4.ip_forward=0') #Disable forwarding on the router
|
self.cmd('sysctl net.ipv4.ip_forward=0') #Disable forwarding on the router
|
||||||
super(MyRouter, self).terminate
|
super(MyRouter, self).terminate()
|
||||||
|
|
||||||
def build_topology(config_file):
|
def build_topology(config_file):
|
||||||
topo = Topo()
|
topo = Topo()
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ class MyRouter (Node):
|
|||||||
self.cmd('sysctl net.ipv4.ip_forward=1') #Enable forwarding on the router
|
self.cmd('sysctl net.ipv4.ip_forward=1') #Enable forwarding on the router
|
||||||
def terminate(self):
|
def terminate(self):
|
||||||
self.cmd('sysctl net.ipv4.ip_forward=0') #Disable forwarding on the router
|
self.cmd('sysctl net.ipv4.ip_forward=0') #Disable forwarding on the router
|
||||||
super(MyRouter, self).terminate
|
super(MyRouter, self).terminate()
|
||||||
|
|
||||||
def build_topology(config_file):
|
def build_topology(config_file):
|
||||||
topo = Topo()
|
topo = Topo()
|
||||||
|
|||||||
@@ -46,6 +46,7 @@ Types: deb
|
|||||||
URIs: https://download.docker.com/linux/ubuntu
|
URIs: https://download.docker.com/linux/ubuntu
|
||||||
Suites: $(. /etc/os-release && echo "${UBUNTU_CODENAME:-$VERSION_CODENAME}")
|
Suites: $(. /etc/os-release && echo "${UBUNTU_CODENAME:-$VERSION_CODENAME}")
|
||||||
Components: stable
|
Components: stable
|
||||||
|
Architectures: $(dpkg --print-architecture)
|
||||||
Signed-By: /etc/apt/keyrings/docker.asc
|
Signed-By: /etc/apt/keyrings/docker.asc
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
|
|||||||
+16
-11
@@ -23,7 +23,7 @@ else
|
|||||||
echo "You choose no"
|
echo "You choose no"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo -e "${YELLOW}Do you want to Install VirtualBox-7.0?: [Y/n]${DEFAULT}"
|
echo -e "${YELLOW}Do you want to Install VirtualBox-7.2?: [Y/n]${DEFAULT}"
|
||||||
read -r confirmation
|
read -r confirmation
|
||||||
if [[ ! "$confirmation" =~ ^[Nn]|[Nn][Oo]$ ]]; then
|
if [[ ! "$confirmation" =~ ^[Nn]|[Nn][Oo]$ ]]; then
|
||||||
echo "Installing..."
|
echo "Installing..."
|
||||||
@@ -35,23 +35,28 @@ if [[ ! "$confirmation" =~ ^[Nn]|[Nn][Oo]$ ]]; then
|
|||||||
lsb-release \
|
lsb-release \
|
||||||
|
|
||||||
echo -e "${BLUE}Adding Docker's official GPG key${DEFAULT}"
|
echo -e "${BLUE}Adding Docker's official GPG key${DEFAULT}"
|
||||||
wget -O- https://www.virtualbox.org/download/oracle_vbox_2016.asc | sudo gpg --yes --dearmor -o /usr/share/keyrings/oracle-virtualbox-2016.gpg
|
wget -qO - https://www.virtualbox.org/download/oracle_vbox_2016.asc | gpg --dearmor | sudo tee /etc/apt/keyrings/oracle-virtualbox-2016.gpg -
|
||||||
|
|
||||||
echo \
|
echo -e "${BLUE}Add the repository to Apt sources${DEFAULT}"
|
||||||
"deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/oracle-virtualbox-2016.gpg] https://download.virtualbox.org/virtualbox/debian \
|
sudo tee /etc/apt/sources.list.d/virtualbox.sources <<EOF
|
||||||
$(. /etc/os-release && echo $VERSION_CODENAME) contrib" | \
|
Types: deb
|
||||||
sudo tee /etc/apt/sources.list.d/virtualbox.list > /dev/null
|
URIs: https://download.virtualbox.org/virtualbox/debian
|
||||||
|
Suites: $(. /etc/os-release && echo "${UBUNTU_CODENAME:-$VERSION_CODENAME}")
|
||||||
|
Components: contrib
|
||||||
|
Architectures: $(dpkg --print-architecture)
|
||||||
|
Signed-By: /etc/apt/keyrings/oracle-virtualbox-2016.gpg
|
||||||
|
EOF
|
||||||
|
|
||||||
sudo apt-get update -y
|
sudo apt-get update -y
|
||||||
sudo apt-get install -y \
|
sudo apt-get install -y \
|
||||||
linux-headers-$(uname -r) \
|
linux-headers-$(uname -r) \
|
||||||
dkms \
|
virtualbox-7.2 \
|
||||||
virtualbox-7.0
|
dkms
|
||||||
|
|
||||||
echo -e "${BLUE}Make VirtualBox run with Extension Pack${DEFAULT}"
|
echo -e "${BLUE}Make VirtualBox run with Extension Pack${DEFAULT}"
|
||||||
wget https://download.virtualbox.org/virtualbox/7.0.14/Oracle_VM_VirtualBox_Extension_Pack-7.0.14.vbox-extpack
|
wget https://download.virtualbox.org/virtualbox/7.2.8/Oracle_VirtualBox_Extension_Pack-7.2.8.vbox-extpack
|
||||||
sudo vboxmanage extpack install --replace --accept-license=33d7284dc4a0ece381196fda3cfe2ed0e1e8e7ed7f27b9a9ebc4ee22e24bd23c Oracle_VM_VirtualBox_Extension_Pack-7.0.14.vbox-extpack
|
sudo vboxmanage extpack install --replace --accept-license=$(sha256sum Oracle_VirtualBox_Extension_Pack-7.2.8.vbox-extpack | awk '{print $1}') Oracle_VirtualBox_Extension_Pack-7.2.8.vbox-extpack
|
||||||
rm -f Oracle_VM_VirtualBox_Extension_Pack-7.0.14.vbox-extpack
|
rm -f Oracle_VirtualBox_Extension_Pack-7.2.8.vbox-extpack
|
||||||
|
|
||||||
echo -e "${BLUE}Make VirtualBox run with admin privileges${DEFAULT}"
|
echo -e "${BLUE}Make VirtualBox run with admin privileges${DEFAULT}"
|
||||||
sudo groupadd vboxusers
|
sudo groupadd vboxusers
|
||||||
|
|||||||
Reference in New Issue
Block a user