---
# Copyright (C) 2017 Maciej Delmanowski <drybjed@gmail.com>
# Copyright (C) 2017 DebOps <https://debops.org/>
# SPDX-License-Identifier: GPL-3.0-only

- name: Configure application with NSS service
  collections: [ 'debops.debops' ]
  hosts: [ 'debops_service_application' ]
  become: True

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

  roles:

    - role: application
      tags: [ 'role::application' ]

    - role: nsswitch
      tags: [ 'role::nsswitch' ]
      nsswitch__dependent_services:
        - '{{ application__nsswitch__dependent_services }}'
