more fixes

This commit is contained in:
xenia 2021-06-15 05:46:27 -04:00
parent b81c78a14e
commit 08d6edb790
1 changed files with 4 additions and 6 deletions

View File

@ -1,5 +1,8 @@
---
- hosts: all
environment:
PATH: '/home/{{ ansible_user }}/.local/bin:{{ ansible_env.PATH }}'
LD_LIBRARY_PATH: '/home/{{ ansible_user }}/.local/lib:{{ ansible_env.get("LD_LIBRARY_PATH", "") }}'
vars:
python_version: 3.9.5
tasks:
@ -19,8 +22,6 @@
executable: "/bin/bash"
shell: |
set -eo pipefail
export PATH=$HOME/.local/bin:$PATH
export LD_LIBRARY_PATH=$HOME/.local/lib:$LD_LIBRARY_PATH
existing_ver="$(python3 -c 'import sys;print(f"{sys.version_info.major}.{sys.version_info.minor}.{sys.version_info.micro}")')"
if [ "$existing_ver" == "{{ python_version }}" ]; then
echo "NO_COMPILE_NEEDED"
@ -58,9 +59,6 @@
state: directory
- name: install python packages
environment:
PATH: '/home/{{ ansible_user }}/.local/bin:{{ ansible_env.PATH }}'
LD_LIBRARY_PATH: '/home/{{ ansible_user }}/.local/lib:{{ ansible_env.get("LD_LIBRARY_PATH", "") }}'
vars:
- base_packages:
- dask
@ -105,7 +103,7 @@
- name: enable linger
command: loginctl enable-linger
changed_when: false
changed_when: true
- name: enable and start systemd task
systemd: