This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import os | |
import socket | |
import subprocess | |
import sys | |
from typing import Any, Dict, Final, List, Tuple | |
import iptc | |
import psutil |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -ex | |
BRIDGE_NAME="br0" | |
BRIDGE_IP="192.168.92.1" | |
setup_bridge() { | |
echo "Setting up bridge $BRIDGE_NAME" | |
ip link add name $BRIDGE_NAME type bridge |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -ex | |
# Function to check if a command succeeded | |
check_command() { | |
if [ $? -ne 0 ]; then | |
echo "Error: $1" | |
exit 1 | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -e | |
sudo -v | |
sudo apt-get update | |
sudo apt-get dist-upgrade -y | |
sudo apt-get autoremove -y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
~/restart_xrdp.sh | |
sudo make clean all -j $(nproc) | |
sudo make install -j $(nproc) | |
sudo systemctl daemon-reload | |
sudo service xrdp restart |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
function kill_all() { | |
process=$1 | |
for i in $(ps aux | grep $process | tr -s ' ' | cut -d" " -f 2) | |
do | |
sudo kill -9 $i | |
done | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -e | |
sudo -v | |
sudo apt-get update | |
sudo apt-get dist-upgrade -y | |
sudo apt-get autoremove -y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -e | |
sudo -v | |
sudo apt install -y make git g++ nasm | |
git clone https://github.com/cisco/openh264.git ~/openh264 | |
cd ~/openh264 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -e | |
cd ~ | |
sudo -v | |
sudo apt-get -y install nvidia-prime vim git mesa-utils net-tools \ | |
gnupg2 software-properties-common apt-transport-https gpg wget \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -e | |
sudo -v | |
sudo apt-get update | |
sudo apt-get dist-upgrade -y | |
sudo apt-get autoremove -y |
NewerOlder