Initial commit
This commit is contained in:
		
							
								
								
									
										35
									
								
								roles/ansible_dependencies/tasks/main.yml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										35
									
								
								roles/ansible_dependencies/tasks/main.yml
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,35 @@ | ||||
| --- | ||||
|  | ||||
| - name: re-synchronize the package index files from their sources | ||||
|   raw: apt-get update | ||||
|    | ||||
| - name: Ensure aptitude is present | ||||
|   raw: test -e /usr/bin/aptitude || apt-get install aptitude -y | ||||
|  | ||||
| - name: Ensure python2 is present (This is necessary for ansible to work properly) | ||||
|   raw: test -e /usr/bin/python2 || (apt -y update && apt install -y python) | ||||
|  | ||||
| - name: Ensure python-apt is present (This is necessary for ansible to work properly) | ||||
|   raw: test -e  /usr/bin/python2 && (apt -y update && apt install -y python-apt) | ||||
|  | ||||
| - name: Ensure python3 is present (This is necessary for ansible to work properly) | ||||
|   raw: test -e /usr/bin/python3 || (apt -y update && apt install -y python3) | ||||
|  | ||||
| - name: Ensure python-apt is present (This is necessary for ansible to work properly) | ||||
|   raw: test -e /usr/bin/python3 || (apt -y update && apt install -y python3-apt) | ||||
|  | ||||
| - name: apt upgrade | ||||
|   apt: | ||||
|     upgrade: dist | ||||
|     update_cache: true | ||||
|     dpkg_options: force-confdef,force-confold | ||||
|   tags: | ||||
|     - ansible-dependencies | ||||
|  | ||||
| - name: apt install ansible dependencies | ||||
|   apt: | ||||
|     name: "{{ apt_ansible_dependencies }}" | ||||
|     state: latest | ||||
|   tags: | ||||
|     - ansible-dependencies | ||||
|  | ||||
		Reference in New Issue
	
	Block a user