From 46e66a20a1c9b84ef7d15c043d96615f0284ed74 Mon Sep 17 00:00:00 2001 From: Karen Zeng Date: Fri, 16 Jun 2023 16:41:22 -0400 Subject: [PATCH] Started snapd.service and installed chromium --- basic_checks.yml | 32 ++++++++++++++++++-------------- 1 file changed, 18 insertions(+), 14 deletions(-) diff --git a/basic_checks.yml b/basic_checks.yml index dc2619c..f614329 100644 --- a/basic_checks.yml +++ b/basic_checks.yml @@ -132,14 +132,23 @@ pip: name: requests state: present - - name: Start snapd and udev - docker_container: - name: loving_benz - command: systemctl start snapd udev + - name: Install snapd package + apt: + name: snapd + state: present + - name: Start udev + systemd: + name: udev + state: started + - name: Start snapd + systemd: + name: snapd.service + # Verify the exact name of the systemd service for snapd using `systemctl list-unit-files | grep snapd` on the host + state: started - name: Install chromium - docker_container: - name: loving_benz - command: snap install chromium + snap: + name: chromium + state: present - name: Install Chromium and Chromedriver hosts: docker_container @@ -156,12 +165,7 @@ - name: Run latest version of scraper hosts: docker_container + become: true tasks: - # TODO use the ansible variable to get the home directory - - name: Clone pricer repository - git: - repo: https://gogs.gtsplab.com:5432/SVIG/pricer.git - dest: /root/pricer - version: master - name: Run scraper - command: python /root/fp_merge.py + command: python3 /opt/pricer/fp_merge.py