Getting started

Example inventory

To configure a NodeJS environment on a given host or set of hosts, they need to be added to [debops_service_nodejs] Ansible group in the inventory:

[debops_service_nodejs]
hostname

Example playbook

If you are using this role without DebOps, here's an example Ansible playbook that uses the debops.nodejs role:

---

- name: Manage NodeJS environment
  hosts: [ 'debops_service_nodejs' ]
  become: True

  environment: '{{ inventory__environment | d({})
                   | combine(inventory__group_environment | d({}))
                   | combine(inventory__host_environment  | d({})) }}'

  roles:

    - role: debops.nodejs
      tags: [ 'role::nodejs' ]