67 lines
1.5 KiB
YAML

---
- hosts: misc
tasks:
- name: Install basic packages
become: yes
apt:
name:
- vim
- git
- htop
- tmux
update_cache: yes
tags:
- apt
- include_role:
name: docker
- name: Install pip prerequisites
become: yes
apt:
name:
- python3-pip
- python3-setuptools
- python3-virtualenv
- name: Install global python docker package
become: yes
pip:
name:
- docker
- docker-compose
- requests
- name: Upload docker configuration
become: yes
copy:
src: ../docker
dest: /etc/pbri
- name: Create global docker volumes
become: yes
docker_volume:
name: "{{ item.name }}"
state: "{{ item.state }}"
loop:
- name: codi_database
state: present
- name: codi_uploads
state: present
- name: gitlab_data
state: present
- name: gitlab_logs
state: present
- name: gitlab_config
state: present
- name: gitlab_runner_config
state: present
- name: gitlab_runner_cache
state: present
- name: Set up docker stuff
become: yes
docker_compose:
project_src: "/etc/pbri/docker/{{ item.name }}"
state: "{{ item.state }}"
build: yes
debug: yes
loop:
- name: web
state: present
- name: runner
state: present