diff --git a/tasks/deploy_netbox.yml b/tasks/deploy_netbox.yml index c0b2d05..a3e1b14 100644 --- a/tasks/deploy_netbox.yml +++ b/tasks/deploy_netbox.yml @@ -86,6 +86,18 @@ - restart netbox.service - restart netbox-rqworker.service +# local_requirements.txt +- name: Copy selected optional Python dependencies to local_requirements.txt + ansible.builtin.copy: + content: | + {% for dep in _netbox_python_deps %} + {{ dep }} + {% endfor %} + dest: "{{ netbox_current_path }}/local_requirements.txt" + owner: "{{ netbox_user }}" + group: "{{ netbox_group }}" + when: (_netbox_python_deps | length) > 0 + - name: NetBox Configuration block: # configuration.py