# FRR in a Docker container: socket\_path must be a value

**URL:** <https://forum.ansible.com/t/frr-in-a-docker-container-socket-path-must-be-a-value/35504>\
**Category:** Ansible Project\
**Created:** [July 13, 2021, 6:38pm UTC](https://forum.ansible.com/t/frr-in-a-docker-container-socket-path-must-be-a-value/35504 "2021-07-13T18:38:30Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Saqib\_Ilyas](https://avatars.discourse-cdn.com/v4/letter/s/c5a1d2/32.png) [@Saqib\_Ilyas](https://forum.ansible.com/u/Saqib_Ilyas)\
**Post date:** [July 13, 2021, 6:38pm UTC](https://forum.ansible.com/t/frr-in-a-docker-container-socket-path-must-be-a-value/35504/1 "2021-07-13T18:38:30Z")

</div>

Hi  
I used containerlab to set up a small topology with a few FRR routers running as Docker containers. Accordingly, I set ansible\_connection: Docker. However, when I run the following playbook:

- name: testing facts  
hosts: routers  
tasks:
- name: Do not collect hardware facts

frr.frr.frr\_facts:  
gather\_subset:

- config

I get the following error:

An exception occurred during task execution. To see the full traceback, use -vvv. The error was: AssertionError: socket\_path must be a value  
fatal: [172.20.20.5]: FAILED! =\> {“changed”: false, “module\_stderr”: “Traceback (most recent call last):\n File "/root/.ansible/tmp/ansible-tmp-1626200560.5446706-211173012575608/AnsiballZ\_frr\_facts.py", line 102, in \n \_ansiballz\_main()\n File "/root/.ansible/tmp/ansible-tmp-1626200560.5446706-211173012575608/AnsiballZ\_frr\_facts.py", line 94, in \_ansiballz\_main\n invoke\_module(zipped\_mod, temp\_path, ANSIBALLZ\_PARAMS)\n File "/root/.ansible/tmp/ansible-tmp-1626200560.5446706-211173012575608/AnsiballZ\_frr\_facts.py", line 40, in invoke\_module\n runpy.run\_module(mod\_name=‘ansible\_collections.frr.frr.plugins.modules.frr\_facts’, init\_globals=None, run\_name=‘ **main** ’, alter\_sys=True)\n File "/usr/lib/python3.8/runpy.py", line 207, in run\_module\n return \_run\_module\_code(code, init\_globals, run\_name, mod\_spec)\n File "/usr/lib/python3.8/runpy.py", line 97, in \_run\_module\_code\n \_run\_code(code, mod\_globals, init\_globals,\n File "/usr/lib/python3.8/runpy.py", line 87, in \_run\_code\n exec(code, run\_globals)\n File "/tmp/ansible\_frr.frr.frr\_facts\_payload\_dcxvzx4f/ansible\_frr.frr.frr\_facts\_payload.zip/ansible\_collections/frr/frr/plugins/modules/frr\_facts.py", line 425, in \n File "/tmp/ansible\_frr.frr.frr\_facts\_payload\_dcxvzx4f/ansible\_frr.frr.frr\_facts\_payload.zip/ansible\_collections/frr/frr/plugins/modules/frr\_facts.py", line 410, in main\n File "/tmp/ansible\_frr.frr.frr\_facts\_payload\_dcxvzx4f/ansible\_frr.frr.frr\_facts\_payload.zip/ansible\_collections/frr/frr/plugins/modules/frr\_facts.py", line 134, in **init** \n File "/tmp/ansible\_frr.frr.frr\_facts\_payload\_dcxvzx4f/ansible\_frr.frr.frr\_facts\_payload.zip/ansible\_collections/frr/frr/plugins/module\_utils/network/frr/frr.py", line 18, in get\_capabilities\n File "/tmp/ansible\_frr.frr.frr\_facts\_payload\_dcxvzx4f/ansible\_frr.frr.frr\_facts\_payload.zip/ansible/module\_utils/connection.py", line 121, in **init** \nAssertionError: socket\_path must be a value\n”, “module\_stdout”: “”, “msg”: “MODULE FAILURE\nSee stdout/stderr for the exact error”, “rc”: 1}

I tried ansible\_connection: network\_cli, but that tries to connect to port 22, and SSH server isn’t running on the FRR containers. Is there a way to direct Ansible to use vtysh to connect to the containers?

Thanks and best regards  
Saqib
