Bläddra i källkod

Commented out a bunch of lines not needed

Chris Hagood 2 år sedan
förälder
incheckning
53a88e3e44
1 ändrade filer med 15 tillägg och 15 borttagningar
  1. 15 15
      UbuntuJoinDomain.sh

+ 15 - 15
UbuntuJoinDomain.sh

@@ -8,8 +8,8 @@ echo "unattended-upgrades unattended-upgrades/enable_auto_updates boolean false"
 sudo dpkg-reconfigure -f noninteractive unattended-upgrades
 
 # mark linux-image-generic and linux-headers-generic as held back
-echo "Marking linux-image-generic and linux-headers-generic as held back..."
-sudo apt-mark hold linux-image-generic linux-headers-generic
+# echo "Marking linux-image-generic and linux-headers-generic as held back..."
+# sudo apt-mark hold linux-image-generic linux-headers-generic
 
 # upgrade the system
 echo "Upgrading the system..."
@@ -21,7 +21,7 @@ sudo DEBIAN_FRONTEND=noninteractive apt install -y realmd libnss-sss libpam-sss
 
 # Install any additional software
 # Required packages for Ninja
-sudo DEBIAN_FRONTEND=noninteractive apt install -y net-tools network-manager policycoreutils
+# sudo DEBIAN_FRONTEND=noninteractive apt install -y net-tools network-manager policycoreutils
 
 # Load configuration file
 source config.sh
@@ -70,39 +70,39 @@ sudo realm deny --all
 
 # Allow login to domain groups
 sudo realm permit -g "Domain Admins"
-sudo realm permit -g "Access - Admin - All Servers"
-sudo realm permit -g "Access - Admin - $HOST"
+# sudo realm permit -g "Access - Admin - All Servers"
+# sudo realm permit -g "Access - Admin - $HOST"
 
 # Set up sudoers file
 echo "%Domain\ Admins     ALL=(ALL:ALL)   ALL" | sudo tee /etc/sudoers.d/LocalAdmins > /dev/null
-echo "%Access\ -\ Admin\ -\ All\ Servers     ALL=(ALL)   ALL" | sudo tee -a /etc/sudoers.d/LocalAdmins > /dev/null
-echo "%Access\ -\ Admin\ -\ $HOST     ALL=(ALL)   ALL" | sudo tee -a /etc/sudoers.d/LocalAdmins > /dev/null
+# echo "%Access\ -\ Admin\ -\ All\ Servers     ALL=(ALL)   ALL" | sudo tee -a /etc/sudoers.d/LocalAdmins > /dev/null
+# echo "%Access\ -\ Admin\ -\ $HOST     ALL=(ALL)   ALL" | sudo tee -a /etc/sudoers.d/LocalAdmins > /dev/null
 
 # copy file from SCP server to local system
-sudo scp -r anonymous@ptiwa001:ninja-agent.deb ~/
+# sudo scp -r anonymous@ptiwa001:ninja-agent.deb ~/
 
 # install package using dpkg
-sudo dpkg -i ninja-agent.deb
+# sudo dpkg -i ninja-agent.deb
 
 # copy file from SCP server to local system
-sudo scp -r anonymous@ptiwa001:falcon-sensor_6.46.0-14306.deb ~/
+# sudo scp -r anonymous@ptiwa001:falcon-sensor_6.46.0-14306.deb ~/
 
 # install package using dpkg
-sudo dpkg -i falcon-sensor_6.46.0-14306.deb
+# sudo dpkg -i falcon-sensor_6.46.0-14306.deb
  
 # Run the additional command
-sudo /opt/CrowdStrike/falconctl -s --cid=D0511099B3FF494D8B87F48C4AB90201-56 
+# sudo /opt/CrowdStrike/falconctl -s --cid=D0511099B3FF494D8B87F48C4AB90201-56 
 
 # Remove packages that are not required
 sudo apt autoremove -y
 
 # Start Services
 sudo systemctl restart sssd
-sudo systemctl start ninjarmm-agent.service
-sudo systemctl start falcon-sensor
+# sudo systemctl start ninjarmm-agent.service
+# sudo systemctl start falcon-sensor
 
 # check the status of the services
-sudo systemctl | grep -E 'falcon-sensor|ninjarmm-agent|sssd.service'
+# sudo systemctl | grep -E 'falcon-sensor|ninjarmm-agent|sssd.service'
 
 # Query user and print message
 id chagood && echo "Successfully queried Active Directory for user chagood"