more isolated task execution tweaking

* set a more reasonable default `AWX_ISOLATED_CHECK_INTERVAL`
* make manual cancellation work for high values of
  `AWX_ISOLATED_CHECK_INTERVAL`
* remove the `/tmp/ansible_tower/jobs/` symlink directory

see: #6616
This commit is contained in:
Ryan Petrello
2017-06-16 11:18:01 -04:00
parent 44e0c8621a
commit 1ea03aa4c9
9 changed files with 36 additions and 37 deletions

View File

@@ -4,7 +4,6 @@
# src: /tmp/some/path/private_data_dir
# dest: /tmp/some/path/
# proot_temp_dir: /tmp/some/path
# job_id: <pk>
- hosts: all
gather_facts: false
@@ -26,20 +25,14 @@
src: "{{src}}"
dest: "{{dest}}"
- name: create a directory for running jobs
file: path=/tmp/ansible_tower/jobs state=directory mode=0700
- name: create symlink keyed by job ID
file: src="{{src}}" dest="/tmp/ansible_tower/jobs/{{job_id}}" state=link
- name: create a named pipe for secret environment data
command: "mkfifo /tmp/ansible_tower/jobs/{{job_id}}/env"
command: "mkfifo {{src}}/env"
- name: spawn the playbook
command: "tower-expect start {{job_id}}"
command: "tower-expect start {{src}}"
- name: write the secret environment data
mkfifo:
content: "{{secret}}"
path: "/tmp/ansible_tower/jobs/{{job_id}}/env"
path: "{{src}}/env"
no_log: True