From f850108a4321d4ad243c8b99a343c28278cac7e5 Mon Sep 17 00:00:00 2001 From: lefos Date: Mon, 1 Nov 2021 00:57:57 +0200 Subject: [PATCH] asd --- mongo.yml | 14 ++++++++------ monitorall.yml.sh | 6 +++--- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/mongo.yml b/mongo.yml index 4a72fb6..2e06879 100644 --- a/mongo.yml +++ b/mongo.yml @@ -41,9 +41,11 @@ # - curl # - lynx # - ruby - - name: Add Mongo packages repo - apt_key: id=2930ADAE8CAF5059EE73BB4B58712A2291FA4AD5 keyserver=keyserver.ubuntu.com - - name: add repo itself - apt_repository: repo='deb http://repo.mongodb.org/apt/ubuntu {{ansible_distribution_release}}/mongodb-org/3.4 multiverse' state=present - - name: install packages - apt: pkg=mongodb-org state=present \ No newline at end of file + - name: Import the public key used by the package management system + apt_key: keyserver=hkp://keyserver.ubuntu.com:80 id=7F0CEB10 state=present + - name: Add MongoDB repository + apt_repository: repo='deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen' state=present + - name: install mongodb + apt: pkg=mongodb-org state=latest update_cache=yes + notify: + - start mongodb \ No newline at end of file diff --git a/monitorall.yml.sh b/monitorall.yml.sh index c6dadf1..fb40e3e 100644 --- a/monitorall.yml.sh +++ b/monitorall.yml.sh @@ -20,11 +20,11 @@ echo "[service]" > /project/courses/Thesis/inventory.yml # include master or not echo $ip4 >> /project/courses/Thesis/inventory.yml -#dummy -ansible-playbook -u docker -i inventory.yml node.yml -f 5 --ask-pass --ask-become-pass +#dummy DONE +# ansible-playbook -u docker -i inventory.yml node.yml -f 5 --ask-pass --ask-become-pass #mongo -# ansible-playbook -u docker -i inventory.yml mongo.yml -f 5 --ask-pass --ask-become-pass +ansible-playbook -u docker -i inventory.yml mongo.yml -f 5 --ask-pass --ask-become-pass # 1st make sudo without password # run with keys