-
I tried to use the netbox container and the machine is up and running now. As a 2nd step I would like to install ansible on it. I have no experience with docker but I am able to get a CLI under portainer... Can someone please give me a hint how to install ansible on it? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I'm afraid you're asking the wrong question, in so many ways :-) Firstly, this is a mailing list for Netbox, not for Ansible. "How do I install Ansible" is not a relevant question here. Secondly, containers are supposed to be deployed separately. You should have one container (or set of containers) for Netbox, and one for Ansible. You don't "install" additional applications inside existing containers; you build new container images and then deploy them. Neither do you manage or upgrade running containers using Ansible or any other config management tool; you build new images and deploy them to replace the old ones. Whilst I don't know what you're actually trying to achieve, perhaps what you want to know is:
To do the first of these, you'd install Ansible on some host somewhere (your management station), and configure it to use the Netbox Ansible inventory plugin. You don't need to install Ansible on the same host or container as Netbox, because Ansible talks to Netbox over the network using its REST API. Once you have Ansible installed on a host you can install the plugin using Then you can create an inventory file
Test this using
At this point you should be able to do To take the second point: if you want to trigger dynamic provisioning actions from changes to Netbox, then you probably want to use Netbox webhooks. As a target for these you could look at Ansible Tower (a.k.a. AWX), which is basically a web frontend to Ansible. I haven't tried integrating the two; I expect you'd have to write a webhook template. Again, because Tower runs on its own server, there's no need for it to be installed on the same host as Netbox. |
Beta Was this translation helpful? Give feedback.
I'm afraid you're asking the wrong question, in so many ways :-)
Firstly, this is a mailing list for Netbox, not for Ansible. "How do I install Ansible" is not a relevant question here.
Secondly, containers are supposed to be deployed separately. You should have one container (or set of containers) for Netbox, and one for Ansible. You don't "install" additional applications inside existing containers; you build new container images and then deploy them. Neither do you manage or upgrade running containers using Ansible or any other config management tool; you build new images and deploy them to replace the old ones.
Whilst I don't know what you're actually trying to achieve, perhaps what y…