blob: c12259f5dda463142eb9175c02910c3f452b097d [file] [log] [blame]
Jessica Wagantall564913e2018-03-19 13:41:33 -07001---
2- import_playbook: ../common-packer/provision/baseline.yaml
Jessica Wagantallc9469342019-10-07 11:35:53 -07003
4- hosts: all
5 become_user: root
6 become_method: sudo
7
Jessica Wagantallf32a5012019-10-07 12:01:32 -07008 tasks:
efiacor27f55b72019-11-27 20:02:52 +00009 - apt_repository:
efiacor27f55b72019-11-27 20:02:52 +000010 repo: ppa:deadsnakes/ppa
11 state: present
12 become: true
13 when: ansible_distribution == 'Ubuntu'
14
Jessica Wagantallc9469342019-10-07 11:35:53 -070015 - name: Update and upgrade apt packages
16 apt:
Andrew Grimberga6b750c2023-05-03 08:47:44 -070017 upgrade: "yes"
18 update_cache: true
Jessica Wagantallc9469342019-10-07 11:35:53 -070019 become: true
20 when: ansible_distribution == 'Ubuntu'
21
Jessica Wagantallc9469342019-10-07 11:35:53 -070022 - name: Install Python 3.6 and packages
23 apt:
24 name:
25 - python3.6
26 - python3.6-dev
27 - python3.6-tk
28 - libssl-dev
29 - libmysqlclient-dev
30 - gcc
Jessica Wagantall175d5ef2020-02-20 10:23:58 -080031 - python3-venv
Jessica Wagantallc9469342019-10-07 11:35:53 -070032 become: true
33 when: ansible_distribution == 'Ubuntu'
34
efiacor27f55b72019-11-27 20:02:52 +000035 - name: Install Python 3.7
36 apt:
37 name:
38 - python3.7
39 - python3.7-dev
40 - python3.7-tk
41 become: true
42 when: ansible_distribution == 'Ubuntu'
43
vv770d4f9ba442020-07-17 20:46:45 +000044 - name: Install Python 3.8
45 apt:
46 name:
47 - python3.8
48 - python3.8-dev
49 - python3.8-tk
50 become: true
51 when: ansible_distribution == 'Ubuntu'
52
Michal Jagiello9f7857e2021-01-22 22:24:57 +000053 - name: Install Python 3.9
54 apt:
55 name:
56 - python3.9
57 - python3.9-dev
58 - python3.9-tk
Bengt Thuree14473ea2021-03-16 13:29:06 +110059 - python3.9-distutils
Michal Jagiello9f7857e2021-01-22 22:24:57 +000060 become: true
61 when: ansible_distribution == 'Ubuntu'
62
Bengt Thuree1c1e1fa2020-03-04 13:01:27 +110063 - name: Install libssl1.0-dev dep
64 apt:
65 name: libssl1.0-dev
Andrew Grimberga6b750c2023-05-03 08:47:44 -070066 update_cache: true
Bengt Thuree1c1e1fa2020-03-04 13:01:27 +110067 state: fixed
68 become: true
69 when: ansible_distribution == 'Ubuntu' and ansible_distribution_version == '18.04'
70
Jessica Wagantalla6a20d72022-09-07 12:00:18 -070071 - name: Install supporting packages (Ubuntu 18.04)
Jessica Wagantallc9469342019-10-07 11:35:53 -070072 apt:
73 name:
74 - unzip
75 - xz-utils
76 - libxml-xpath-perl
77 - wget
78 - make
Jessica Wagantallc9469342019-10-07 11:35:53 -070079 - sshuttle
80 - netcat
81 - libssl-dev
82 - libffi-dev
Jessica Wagantallc9469342019-10-07 11:35:53 -070083 - xmlstarlet
84 - xvfb
85 - crudini
86 - maven
87 - python-ncclient
Andrew Grimberga6b750c2023-05-03 08:47:44 -070088 update_cache: true
Jessica Wagantalla6a20d72022-09-07 12:00:18 -070089 state: fixed
90 become: true
91 when: ansible_distribution == 'Ubuntu' and ansible_distribution_version == '18.04'
92
93 - name: Install supporting packages (Ubuntu 20.04)
94 apt:
95 name:
96 - unzip
97 - xz-utils
98 - libxml-xpath-perl
99 - wget
100 - make
101 - sshuttle
102 - netcat
103 - libssl-dev
104 - libffi-dev
Jessica Wagantall25201972020-02-19 12:00:04 -0800105 - xmlstarlet
106 - xvfb
107 - crudini
108 - maven
Bengt Thuree1610dcb2022-09-08 19:26:17 +1000109 - python3-ncclient
Andrew Grimberga6b750c2023-05-03 08:47:44 -0700110 update_cache: true
Jessica Wagantalla6a20d72022-09-07 12:00:18 -0700111 state: fixed
Jessica Wagantallc9469342019-10-07 11:35:53 -0700112 become: true
Jessica Wagantalla6a20d72022-09-07 12:00:18 -0700113 when: ansible_distribution == 'Ubuntu' and ansible_distribution_version == '20.04'
Bengt Thuree1c1e1fa2020-03-04 13:01:27 +1100114
Jessica Wagantall049b42e2023-04-11 14:37:26 -0700115 - name: Install nodejs and npm
116 block:
Andrew Grimberga6b750c2023-05-03 08:47:44 -0700117 - name: "Pull latest nodejs version"
Jessica Wagantall36defa92023-04-11 15:45:04 -0700118 shell: |
119 curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash - && sudo apt-get install -y nodejs
Andrew Grimberga6b750c2023-05-03 08:47:44 -0700120 become: true
121 - name: "Check nodejs version"
Jessica Wagantall049b42e2023-04-11 14:37:26 -0700122 command: node --version
Andrew Grimberga6b750c2023-05-03 08:47:44 -0700123 - name: "Check npm version"
Jessica Wagantall049b42e2023-04-11 14:37:26 -0700124 command: npm --version
125 when: ansible_distribution == 'Ubuntu'
126
127 - name: Install npm build tools
Bengt Thuree1c1e1fa2020-03-04 13:01:27 +1100128 apt:
Jessica Wagantall049b42e2023-04-11 14:37:26 -0700129 name: build-essential
Andrew Grimberga6b750c2023-05-03 08:47:44 -0700130 update_cache: true
Bengt Thuree1c1e1fa2020-03-04 13:01:27 +1100131 state: fixed
132 become: true
133 when: ansible_distribution == 'Ubuntu'
134
Bengt Thuree737eca22022-10-13 12:50:30 +1100135 - name: Install enchant2 package for Ubuntu 20.04
Bengt Thureefb285eb2022-10-07 11:17:11 +1100136 apt:
137 name:
138 - enchant-2
Andrew Grimberga6b750c2023-05-03 08:47:44 -0700139 update_cache: true
Bengt Thureefb285eb2022-10-07 11:17:11 +1100140 state: present
141 become: true
Bengt Thuree737eca22022-10-13 12:50:30 +1100142 when: ansible_distribution == 'Ubuntu' and ansible_distribution_version == '20.04'
143
144 - name: Install enchant package for Ubuntu 18.04
145 apt:
146 name:
147 - enchant
Andrew Grimberga6b750c2023-05-03 08:47:44 -0700148 update_cache: true
Bengt Thuree737eca22022-10-13 12:50:30 +1100149 state: present
150 become: true
151 when: ansible_distribution == 'Ubuntu' and ansible_distribution_version == '18.04'
Bengt Thuree1c1e1fa2020-03-04 13:01:27 +1100152
Bengt Thureefb285eb2022-10-07 11:17:11 +1100153 - name: Install enchant2 package for CentOS
154 dnf:
155 name:
156 - enchant2
Andrew Grimberga6b750c2023-05-03 08:47:44 -0700157 update_cache: true
Bengt Thureefb285eb2022-10-07 11:17:11 +1100158 state: present
159 become: true
160 when: ansible_distribution == 'CentOS'