Skip to content
Snippets Groups Projects
Commit 6b99e729 authored by Sara Stentvedt Luggenes's avatar Sara Stentvedt Luggenes
Browse files

Merge branch 'main' of gitlab.stud.idi.ntnu.no:raphaesl/dcsg2003

parents 9fa37e5a 6790ddb0
No related branches found
No related tags found
No related merge requests found
...@@ -12,18 +12,12 @@ sudo apt-get -y install \ ...@@ -12,18 +12,12 @@ sudo apt-get -y install \
git \ git \
gnupg \ gnupg \
lsb-release lsb-release
apt-get -y update
# Add Docker’s official GPG key:
apt-get -y update apt-get -y update
mkdir -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
# Use the following command to set up the repository: # Use the following command to set up the repository:
echo \ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \ add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null apt-get -y update
# Fix potentially broken mask # Fix potentially broken mask
chmod a+r /etc/apt/keyrings/docker.gpg chmod a+r /etc/apt/keyrings/docker.gpg
...@@ -35,9 +29,6 @@ apt-get -y update ...@@ -35,9 +29,6 @@ apt-get -y update
# Install Docker Engine, containerd, and Docker Compose. # Install Docker Engine, containerd, and Docker Compose.
#sudo apt-get -y install docker-ce docker-ce-cli containerd.io docker-compose-plugin #sudo apt-get -y install docker-ce docker-ce-cli containerd.io docker-compose-plugin
# Add to docker swarm cluster as worker
#docker swarm join --token SWMTKN-1-2b8s5pumm6c5liipvnp0gyv613hm9u5r6c567xjirtce1ng8bu-0kyd30qzbbnuvxi4p8c724ft8 192.168.133.95:2377
# Fix potentially broken docker build # Fix potentially broken docker build
echo "{ \"insecure-registries\" : [\"192.168.128.23:5000\"] }" > /etc/docker/daemon.json echo "{ \"insecure-registries\" : [\"192.168.128.23:5000\"] }" > /etc/docker/daemon.json
...@@ -46,6 +37,9 @@ systemctl disable docker ...@@ -46,6 +37,9 @@ systemctl disable docker
systemctl disable docker.service systemctl disable docker.service
systemctl disable docker.socket systemctl disable docker.socket
# Add to docker swarm cluster as worker
#docker swarm join --token SWMTKN-1-2b8s5pumm6c5liipvnp0gyv613hm9u5r6c567xjirtce1ng8bu-0kyd30qzbbnuvxi4p8c724ft8 192.168.133.95:2377
# Sync time using NTP # Sync time using NTP
apt-get install -y ntpdate apt-get install -y ntpdate
ntpdate -b ntp.justervesenet.no ntpdate -b ntp.justervesenet.no
......
# Crontab for manager root user # Crontab for manager root user
* * * * * crontab < /home/ubuntu/dcsg2003/configuration/manager/cron
0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58 * * * * bash /home/ubuntu/dcsg2003/configuration/manager/downDetector.sh 0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58 * * * * bash /home/ubuntu/dcsg2003/configuration/manager/downDetector.sh
* * * * * bash /home/ubuntu/dcsg2003/configuration/manager/pollGit.sh * * * * * bash /home/ubuntu/dcsg2003/configuration/manager/pollGit.sh
* 0,1,2,3,4,5,6,7,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23 * * * ssh root@192.168.130.246 bash /home/ubuntu/dcsg2003/configuration/database/checkDbStatus.sh * 0,1,2,3,4,5,6,7,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23 * * * ssh root@192.168.130.246 bash /home/ubuntu/dcsg2003/configuration/database/checkDbStatus.sh
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment