mirror of
https://github.com/telekom-security/tpotce.git
synced 2025-04-28 19:28:50 +00:00
tweaking
This commit is contained in:
parent
00dd446f7d
commit
c955d641c3
1 changed files with 11 additions and 14 deletions
|
@ -150,24 +150,17 @@ tee -a /etc/ssh/ssh_config <<EOF
|
||||||
UseRoaming no
|
UseRoaming no
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
# Let's add the docker repository
|
|
||||||
fuECHO "### Adding the docker repository."
|
|
||||||
apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
|
|
||||||
tee /etc/apt/sources.list.d/docker.list <<EOF
|
|
||||||
deb https://apt.dockerproject.org/repo ubuntu-xenial main
|
|
||||||
EOF
|
|
||||||
|
|
||||||
# Let's pull some updates
|
# Let's pull some updates
|
||||||
fuECHO "### Pulling Updates."
|
fuECHO "### Pulling Updates."
|
||||||
apt-get update -y
|
apt-get update -y
|
||||||
|
|
||||||
# Let's install docker
|
# Let's install docker
|
||||||
fuECHO "### Installing docker-engine."
|
fuECHO "### Installing docker-engine."
|
||||||
apt-get install docker-engine=1.11.1-0~xenial -y
|
wget -qO- https://get.docker.com/ | sh
|
||||||
|
|
||||||
# Let's enable docker at boot and start service
|
# Let's enable docker at boot and start service
|
||||||
systemctl enable docker
|
#systemctl enable docker
|
||||||
systemctl start docker
|
#systemctl start docker
|
||||||
|
|
||||||
# Let's add proxy settings to docker defaults
|
# Let's add proxy settings to docker defaults
|
||||||
if [ -f $myPROXYFILEPATH ];
|
if [ -f $myPROXYFILEPATH ];
|
||||||
|
@ -207,6 +200,9 @@ tee -a /etc/default/docker <<EOF
|
||||||
DOCKER_OPTS="-r=false"
|
DOCKER_OPTS="-r=false"
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
|
# Let's restart docker for proxy changes to take effect
|
||||||
|
systemctl restart docker
|
||||||
|
|
||||||
# Let's make sure only myFLAVOR images will be downloaded and started
|
# Let's make sure only myFLAVOR images will be downloaded and started
|
||||||
case $myFLAVOR in
|
case $myFLAVOR in
|
||||||
HP)
|
HP)
|
||||||
|
@ -327,10 +323,15 @@ chown tpot:tpot -R /data
|
||||||
chmod 600 /home/tsec/.ssh/authorized_keys
|
chmod 600 /home/tsec/.ssh/authorized_keys
|
||||||
chown tsec:tsec /home/tsec/*.sh /home/tsec/.ssh /home/tsec/.ssh/authorized_keys
|
chown tsec:tsec /home/tsec/*.sh /home/tsec/.ssh /home/tsec/.ssh/authorized_keys
|
||||||
|
|
||||||
|
# Installing upgrades
|
||||||
|
fuECHO "### Installing Upgrades."
|
||||||
|
apt-get upgrade -y
|
||||||
|
|
||||||
# Let's clean up apt
|
# Let's clean up apt
|
||||||
apt-get autoclean -y
|
apt-get autoclean -y
|
||||||
apt-get autoremove -y
|
apt-get autoremove -y
|
||||||
|
|
||||||
|
# Installing upgrades
|
||||||
# Let's replace "quiet splash" options, set a console font for more screen canvas and update grub
|
# Let's replace "quiet splash" options, set a console font for more screen canvas and update grub
|
||||||
sed -i 's#GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"#GRUB_CMDLINE_LINUX_DEFAULT="consoleblank=0"#' /etc/default/grub
|
sed -i 's#GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"#GRUB_CMDLINE_LINUX_DEFAULT="consoleblank=0"#' /etc/default/grub
|
||||||
sed -i 's#\#GRUB_GFXMODE=640x480#GRUB_GFXMODE=800x600x32#' /etc/default/grub
|
sed -i 's#\#GRUB_GFXMODE=640x480#GRUB_GFXMODE=800x600x32#' /etc/default/grub
|
||||||
|
@ -359,10 +360,6 @@ ip = $myEXTIP
|
||||||
EOF
|
EOF
|
||||||
chown tpot:tpot /data/ews/conf/ews.ip
|
chown tpot:tpot /data/ews/conf/ews.ip
|
||||||
|
|
||||||
# Installing upgrades
|
|
||||||
fuECHO "### Installing Upgrades."
|
|
||||||
apt-get upgrade -y
|
|
||||||
|
|
||||||
# Final steps
|
# Final steps
|
||||||
fuECHO "### Thanks for your patience. Now rebooting."
|
fuECHO "### Thanks for your patience. Now rebooting."
|
||||||
mv /root/tpot/etc/rc.local /etc/rc.local && rm -rf /root/tpot/ && chage -d 0 tsec && sleep 2 && reboot
|
mv /root/tpot/etc/rc.local /etc/rc.local && rm -rf /root/tpot/ && chage -d 0 tsec && sleep 2 && reboot
|
||||||
|
|
Loading…
Reference in a new issue