# Cannot run playbook inside AWX

**URL:** <https://forum.ansible.com/t/cannot-run-playbook-inside-awx/32269>\
**Category:** AWX Project\
**Tags:** awx, galaxy-ng\
**Created:** [February 19, 2020, 10:15am UTC](https://forum.ansible.com/t/cannot-run-playbook-inside-awx/32269 "2020-02-19T10:15:28Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![A\_Constantin](https://avatars.discourse-cdn.com/v4/letter/a/4491bb/32.png) [@A\_Constantin](https://forum.ansible.com/u/A_Constantin)\
**Post date:** [February 19, 2020, 10:15am UTC](https://forum.ansible.com/t/cannot-run-playbook-inside-awx/32269/1 "2020-02-19T10:15:28Z")

</div>

##### SUMMARY

I am running AWX Docker setup and I just try to run a simple playbook: [https://galaxy.ansible.com/dapiced/patch\_update\_yum/patch\_update\_yum](https://galaxy.ansible.com/dapiced/patch_update_yum/patch_update_yum)

Which from the command line it runs perfectly, it does what it should, but when running it from a project within AWX it does not run.

##### ENVIRONMENT- AWX version: 6.1.0.0

- AWX install method: docker on linux
- Ansible version: 2.8.2
- Operating System: Red Hat 7.6
- Web Browser: Firefox Quantum 61.0.1 (64-bit)

##### STEPS TO REPRODUCE1. Setup a new playbook within: /var/lib/awx/projects/

1. Setup Inventory and Project to run the playbook
2. Run the playbook

##### EXPECTED RESULTS

PLAY RECAP \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
hostname : ok=2 changed=2 unreachable=0 failed=0

##### ACTUAL RESULTS

PLAYBOOK: site.yml \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
1 plays in site.yml

PLAY [Run patching operation tasks] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
18:40:04

META: ran handlers  
META: ran handlers  
META: ran handlers

PLAY RECAP \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
18:40:04

But no change happened.

##### ADDITIONAL INFORMATION

I’ve checked docker logs, especially for the awx\_task container but no error is being reported:

###### docker logs -f awx\_task --tail 100

```auto
2020-02-18 17:40:01,468 DEBUG awx.main.dispatch delivered 6d29fff9-8d4a-42ab-becb-a0fa1689184b to worker[195] qsize 0
RESULT 2
OKREADY
2020-02-18 17:40:01,472 DEBUG awx.main.dispatch task 6d29fff9-8d4a-42ab-becb-a0fa1689184b starting awx.main.tasks.update_inventory_computed_fields(*[5, True])
2020-02-18 17:40:01,483 DEBUG awx.main.models.inventory Going to update inventory computed fields, pk=5
2020-02-18 17:40:01,520 DEBUG awx.main.models.inventory Finished updating inventory computed fields, pk=5, in 0.036 seconds
2020-02-18 17:40:01,522 DEBUG awx.main.dispatch task 6d29fff9-8d4a-42ab-becb-a0fa1689184b is finished
2020-02-18 17:40:01,600 DEBUG awx.main.dispatch delivered 14e4b576-1ee4-496b-99f7-f62f339e5ca7 to worker[198] qsize 0
2020-02-18 17:40:01,608 DEBUG awx.main.dispatch task 14e4b576-1ee4-496b-99f7-f62f339e5ca7 starting awx.main.scheduler.tasks.run_task_manager(*[])
2020-02-18 17:40:01,612 DEBUG awx.main.scheduler Running Tower task manager.
2020-02-18 17:40:01,630 DEBUG awx.main.scheduler Starting Scheduler
2020-02-18 17:40:01,730 DEBUG awx.main.scheduler Starting job 248 (pending) in group tower instance awx (remaining_capacity=17)
2020-02-18 17:40:01,740 DEBUG awx.main.scheduler Submitting job 248 (waiting) to <instance group, instance> <1,awx>.
2020-02-18 17:40:01,796 DEBUG awx.main.scheduler job 248 (waiting) consumed 3 capacity units from tower with prior total of 0
2020-02-18 17:40:01,804 DEBUG awx.main.dispatch publish awx.main.tasks.RunJob(04bc5dd3-7408-44ce-8201-6d08e2bb9abf, queue=awx)
2020-02-18 17:40:01,835 DEBUG awx.main.dispatch delivered 04bc5dd3-7408-44ce-8201-6d08e2bb9abf to worker[197] qsize 0
2020-02-18 17:40:01,843 DEBUG awx.main.dispatch task 04bc5dd3-7408-44ce-8201-6d08e2bb9abf starting awx.main.tasks.RunJob(*[248])
2020-02-18 17:40:01,843 DEBUG awx.main.dispatch task 14e4b576-1ee4-496b-99f7-f62f339e5ca7 is finished
2020-02-18 17:40:04,638 INFO awx.main.commands.run_callback_receiver Event processing is finished for Job 248, sending notifications
2020-02-18 17:40:04,638 INFO awx.main.commands.run_callback_receiver Event processing is finished for Job 248, sending notifications
2020-02-18 17:40:04,656 DEBUG awx.main.models.inventory Going to update inventory computed fields, pk=5
2020-02-18 17:40:04,693 DEBUG awx.main.models.inventory Finished updating inventory computed fields, pk=5, in 0.034 seconds
2020-02-18 17:40:04,737 DEBUG awx.main.tasks job 248 (running) finished running, producing 18 events.
2020-02-18 17:40:04,825 DEBUG awx.main.dispatch publish awx.main.tasks.update_inventory_computed_fields(6c67bec5-70f5-4122-93f3-89ee4ba4082b, queue=awx_private_queue)
2020-02-18 17:40:04,839 DEBUG awx.main.dispatch delivered 6c67bec5-70f5-4122-93f3-89ee4ba4082b to worker[196] qsize 0
2020-02-18 17:40:04,843 DEBUG awx.main.dispatch task 6c67bec5-70f5-4122-93f3-89ee4ba4082b starting awx.main.tasks.update_inventory_computed_fields(*[5, True])
2020-02-18 17:40:04,846 DEBUG awx.main.dispatch task 04bc5dd3-7408-44ce-8201-6d08e2bb9abf starting awx.main.tasks.handle_work_success(*[])
2020-02-18 17:40:04,851 DEBUG awx.main.dispatch publish awx.main.scheduler.tasks.run_task_manager(1855cec3-c69f-4170-92b7-86fe0cabcb99, queue=awx_private_queue)
2020-02-18 17:40:04,859 DEBUG awx.main.models.inventory Going to update inventory computed fields, pk=5
2020-02-18 17:40:04,875 DEBUG awx.main.dispatch delivered 1855cec3-c69f-4170-92b7-86fe0cabcb99 to worker[198] qsize 0
2020-02-18 17:40:04,874 DEBUG awx.main.dispatch task 04bc5dd3-7408-44ce-8201-6d08e2bb9abf is finished
2020-02-18 17:40:04,881 DEBUG awx.main.dispatch task 1855cec3-c69f-4170-92b7-86fe0cabcb99 starting awx.main.scheduler.tasks.run_task_manager(*[])
2020-02-18 17:40:04,889 DEBUG awx.main.scheduler Running Tower task manager.
2020-02-18 17:40:04,908 DEBUG awx.main.models.inventory Finished updating inventory computed fields, pk=5, in 0.047 seconds
2020-02-18 17:40:04,909 DEBUG awx.main.dispatch task 6c67bec5-70f5-4122-93f3-89ee4ba4082b is finished
2020-02-18 17:40:04,919 DEBUG awx.main.scheduler Starting Scheduler

```

> **(attachments)**
>
> ![PlaybookRun.PNG](https://us1.discourse-cdn.com/ansible/original/2X/7/7f56f467353360df7fccd8a664dee82c9aed5432.png)

---

<div class="post-metadata">

**Author:** ![Angel\_Rengifo\_Cancin](https://avatars.discourse-cdn.com/v4/letter/a/9e8a1a/32.png) [@Angel\_Rengifo\_Cancin](https://forum.ansible.com/u/Angel_Rengifo_Cancin)\
**Post date:** [February 19, 2020, 12:23pm UTC](https://forum.ansible.com/t/cannot-run-playbook-inside-awx/32269/2 "2020-02-19T12:23:56Z")

</div>

Hi:

---

<div class="post-metadata">

**Author:** ![A\_Constantin](https://avatars.discourse-cdn.com/v4/letter/a/4491bb/32.png) [@A\_Constantin](https://forum.ansible.com/u/A_Constantin)\
**Post date:** [February 19, 2020, 1:44pm UTC](https://forum.ansible.com/t/cannot-run-playbook-inside-awx/32269/3 "2020-02-19T13:44:19Z")

</div>

Hi Angel,

I run the playbook manually, like:

# ansible-playbook -i hosts site.yml

PLAY [Run patching operation tasks] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*

TASK [sec\_patch : Package update] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
changed: [hostname-rhel73]

RUNNING HANDLER [sec\_patch : Server reboot if needed] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
changed: [hostname-rhel73]

PLAY RECAP \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
hostname-rhel73 : ok=2 changed=2 unreachable=0 failed=0

The main role playbook file:

> **(attachments)**
>
> ![PlaybookRunTemplate.PNG](https://us1.discourse-cdn.com/ansible/original/2X/3/3f7a6ebf7dcf270edb88dd4e6714eb82e6369061.png)

---

<div class="post-metadata">

**Author:** ![Angel\_Rengifo\_Cancin](https://avatars.discourse-cdn.com/v4/letter/a/9e8a1a/32.png) [@Angel\_Rengifo\_Cancin](https://forum.ansible.com/u/Angel_Rengifo_Cancin)\
**Post date:** [February 20, 2020, 12:35am UTC](https://forum.ansible.com/t/cannot-run-playbook-inside-awx/32269/4 "2020-02-20T00:35:03Z")

</div>

Hi:

I’ve reproduced your playbook and role, both manually and through AWX, it works pretty fine. The only strange thing I’ve noticed in your job template definition is the use of rhel\_sec\_yum tag, which isn’t present on your playbook. If I put such tag or any other one, then job template does nothing, as it’s happening to you.

Remove that tag from your job template and try again, it should work.

---

<div class="post-metadata">

**Author:** ![A\_Constantin](https://avatars.discourse-cdn.com/v4/letter/a/4491bb/32.png) [@A\_Constantin](https://forum.ansible.com/u/A_Constantin)\
**Post date:** [March 2, 2020, 4:29pm UTC](https://forum.ansible.com/t/cannot-run-playbook-inside-awx/32269/5 "2020-03-02T16:29:49Z")

</div>

Thanks, a lot Angel, I was not aware of that.
