--- - name: Deploy {{ svc.name }} tags: - telegraf - monitoring block: - import_tasks: steps/create-service-directory.yml - import_tasks: steps/template-docker-compose.yml - name: Template config ansible.builtin.template: src: telegraf.conf.j2 dest: "{{ (service_path, 'telegraf.conf') | path_join }}" mode: "0664" register: cmd_result - name: Set the docker force-recreate flag ansible.builtin.set_fact: docker_force_recreate: "--force-recreate" when: cmd_result.changed - import_tasks: steps/start-service.yml