python.yml 1.12 KB
Newer Older
julian.gethmann's avatar
julian.gethmann committed
1
2
---
- name: Software for dependency installation
julian.gethmann's avatar
julian.gethmann committed
3
4
  dnf:
    name: "{{ item }}"
julian.gethmann's avatar
julian.gethmann committed
5
    state: present
julian.gethmann's avatar
julian.gethmann committed
6
7
  become: yes
  with_items:
8
9
10
11
12
13
14
15
16
17
  - gcc
  - gcc-c++
  - glibc-devel.x86_64
  - openssl-devel
  # - atlas-devel
  - python-devel
  - lapack-devel
  - numpy-f2py
  # iminuit
  - redhat-rpm-config
julian.gethmann's avatar
julian.gethmann committed
18
19
20
  when: ansible_distribution == 'Fedora'

- name: "Install Python stack for scientific purposes (Distribution)"
julian.gethmann's avatar
julian.gethmann committed
21
22
  package:
    name: "{{ item }}"
julian.gethmann's avatar
julian.gethmann committed
23
    state: present
julian.gethmann's avatar
julian.gethmann committed
24
  become: yes
julian.gethmann's avatar
julian.gethmann committed
25
  with_items:
julian.gethmann's avatar
julian.gethmann committed
26
27
28
  - "{{ python2pkg }}"
  - "{{ python3pkg }}"

julian.gethmann's avatar
julian.gethmann committed
29
30
31
32
33
34
35
  # - name: upgrade pip2  # install --upgrade pip
  #   pip:
  #     name: pip
  #     state: latest
  #   become: yes
  #   tags:
  #     - skip_ansible_lint
julian.gethmann's avatar
julian.gethmann committed
36
37

- name: install pip packages Python 2
38
39
  pip:
    name: "{{ item }}"
julian.gethmann's avatar
julian.gethmann committed
40
    state: present
julian.gethmann's avatar
julian.gethmann committed
41
42
43
  become: yes
  with_items: "{{python2pip}}"

julian.gethmann's avatar
julian.gethmann committed
44
45
46
47
48
49
50
51
  # - name: upgrade pip3
  #   pip:
  #     executable: pip-3
  #     state: latest
  #     name: pip
  #   become: yes
  #   tags:
  #     - skip_ansible_lint
julian.gethmann's avatar
julian.gethmann committed
52
53

- name: install pip packages Python 2
julian.gethmann's avatar
julian.gethmann committed
54
  become: yes
55
  pip:
julian.gethmann's avatar
julian.gethmann committed
56
    executable: "{{ pip3bin }}"
57
    name: "{{ item }}"
julian.gethmann's avatar
julian.gethmann committed
58
    state: present
julian.gethmann's avatar
julian.gethmann committed
59
  with_items: "{{python3pip}}"