Skip to content

Commit

Permalink
[docs] Add instructions for installing role from GitHub
Browse files Browse the repository at this point in the history
  • Loading branch information
lae committed Nov 29, 2024
1 parent fea39ad commit b29e272
Showing 1 changed file with 13 additions and 6 deletions.
19 changes: 13 additions & 6 deletions README.adoc
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
:role-author: lae
:role-name: netbox
:role: {role-author}.{role-name}
:role-version: 1.0.7
:gh-name: {role-author}/ansible-role-{role-name}
:netbox-version: 3.7.3
= {role}
Expand All @@ -12,10 +13,6 @@ ifdef::env-github[]
:warning-caption: :warning:
endif::[]

ifdef::env-github[]
image:https://img.shields.io/badge/role-{role}-blue?style=for-the-badge[Ansible Galaxy Role,link=https://galaxy.ansible.com/{role-author}/{role-name}]
endif::env-github[]

Deploys and configures https://github.com/netbox-community/netbox[NetBox], an IP address management (IPAM) and data center infrastructure management (DCIM) tool.

This role will deploy NetBox within its own virtualenv either by release tarball or via git using uWSGI as the application server.
Expand All @@ -30,13 +27,23 @@ The main differences are:
* Hardens the NetBox/uWSGI service (see `templates/netbox.service.j2`)
* Will hot reload on upgrades and configuration changes
To install this role, add the following to your `requirements.yml`:

[source,yaml,subs="attributes"]
----
---
- name: {role}
src: https://github.com/{gh-name}.git
version: v{role-version}
----

== Quickstart

Provided you have Ansible installed and are using defaults:

[source,bash,subs="attributes"]
----
ansible-galaxy install geerlingguy.postgresql davidwittman.redis {role}
ansible-galaxy install geerlingguy.postgresql davidwittman.redis https://github.com/{gh-name}/archive/refs/tags/v{role-version}.tar.gz,{role}
ansible-galaxy collection install community.postgresql
ansible-playbook -i your.server.fqdn, ~/.ansible/roles/{role}/examples/playbook_single_host_deploy.yml -K
----
Expand All @@ -48,7 +55,7 @@ You can also use Vagrant, if you prefer, to bring up NetBox at `localhost:8080`:

[source,bash,subs="attributes"]
----
ansible-galaxy install geerlingguy.postgresql davidwittman.redis {role}
ansible-galaxy install geerlingguy.postgresql davidwittman.redis https://github.com/{gh-name}/archive/refs/tags/v{role-version}.tar.gz,{role}
ansible-galaxy collection install community.postgresql
cd ~/.ansible/roles/{role}/
vagrant up
Expand Down

0 comments on commit b29e272

Please sign in to comment.