mirror of
https://github.com/roles-ansible/ansible_role_avahi_client.git
synced 2024-08-16 16:09:49 +02:00
commit
211b2f7ed9
8 changed files with 36 additions and 60 deletions
18
.github/workflows/ansible-debian-stretch.yml
vendored
18
.github/workflows/ansible-debian-stretch.yml
vendored
|
@ -1,18 +0,0 @@
|
|||
---
|
||||
name: Ansible check debian:stretch
|
||||
|
||||
# yamllint disable-line rule:truthy
|
||||
on: [push, pull_request]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: 'checkout git repo'
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: 'ansible check with debian:stretch'
|
||||
uses: roles-ansible/check-ansible-debian-stretch-action@master
|
||||
with:
|
||||
targets: "./"
|
7
.github/workflows/ansible-linting-check.yml
vendored
7
.github/workflows/ansible-linting-check.yml
vendored
|
@ -10,13 +10,18 @@ on:
|
|||
|
||||
jobs:
|
||||
build:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: 'checkout git repo'
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
lfs: true
|
||||
submodules: true
|
||||
fetch-depth: 0
|
||||
|
||||
- name: 'Lint Ansible Playbook'
|
||||
uses: ansible/ansible-lint-action@v6
|
||||
with:
|
||||
targets: "."
|
||||
path: "."
|
||||
|
|
18
.github/workflows/ansible-ubuntu-trusty.yml
vendored
18
.github/workflows/ansible-ubuntu-trusty.yml
vendored
|
@ -1,18 +0,0 @@
|
|||
---
|
||||
name: Ansible check ubuntu:trusty
|
||||
|
||||
# yamllint disable-line rule:truthy
|
||||
on: [push, pull_request]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: 'checkout git repo'
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: ansible check with ubuntu:trusty
|
||||
uses: roles-ansible/check-ansible-ubuntu-trusty-action@master
|
||||
with:
|
||||
targets: "./"
|
|
@ -2,21 +2,25 @@
|
|||
galaxy_info:
|
||||
role_name: avahi_client
|
||||
author: do1jlr
|
||||
description: Avahi provides local hostname resolution using a "hostname.local" naming scheme.
|
||||
description: Avahi provides local hostname resolution using the ".local" MDNS Domain.
|
||||
license: "MIT"
|
||||
min_ansible_version: 2.11
|
||||
github_branch: main
|
||||
min_ansible_version: "2.12"
|
||||
platforms:
|
||||
- name: Archlinux
|
||||
versions: all
|
||||
- name: ArchLinux
|
||||
versions: ['all']
|
||||
- name: Debian
|
||||
versions: all
|
||||
versions: ['all']
|
||||
- name: Ubuntu
|
||||
versions: all
|
||||
versions: ['all']
|
||||
- name: EL
|
||||
versions: ['all']
|
||||
- name: Fedora
|
||||
versions: ['all']
|
||||
galaxy_tags:
|
||||
- avahi
|
||||
- client
|
||||
- local
|
||||
- mdns
|
||||
- bonjour
|
||||
- linux
|
||||
dependencies: []
|
||||
|
|
|
@ -1,17 +1,17 @@
|
|||
---
|
||||
- name: run optional versionscheck
|
||||
- name: Run Optional versionscheck
|
||||
ansible.builtin.include_tasks: versioncheck.yml
|
||||
when: submodules_versioncheck|bool
|
||||
when: submodules_versioncheck | bool
|
||||
|
||||
- name: gather os specific variables
|
||||
- name: Gather os specific variables
|
||||
ansible.builtin.include_vars: "{{ item }}"
|
||||
with_first_found:
|
||||
- "vars/{{ ansible_os_family }}.yml"
|
||||
- "vars/os_fallback.yml"
|
||||
|
||||
- name: install mdns requirements
|
||||
- name: Install MDNS requirements
|
||||
ansible.builtin.include_tasks: install.yml
|
||||
|
||||
- name: configure /etc/nsswitch.conf
|
||||
- name: Configure /etc/nsswitch.conf
|
||||
ansible.builtin.include_tasks: nsswitch.yml
|
||||
when: avahi_client__configure_nsswitch | bool
|
||||
|
|
|
@ -8,37 +8,38 @@
|
|||
path: '/etc/.ansible-version'
|
||||
state: directory
|
||||
mode: 0755
|
||||
when: submodules_versioncheck|bool
|
||||
when: submodules_versioncheck | bool
|
||||
|
||||
- name: check playbook version
|
||||
- name: Check playbook version
|
||||
become: true
|
||||
ansible.builtin.slurp:
|
||||
src: "/etc/.ansible-version/{{ playbook_version_path }}"
|
||||
register: playbook_version
|
||||
when: submodules_versioncheck|bool
|
||||
when: submodules_versioncheck | bool
|
||||
ignore_errors: true
|
||||
failed_when: false
|
||||
|
||||
- name: Print remote role version
|
||||
ansible.builtin.debug:
|
||||
msg: "Remote role version: {{ playbook_version.content | default('Y3VycmVudGx5IG5vdCBkZXBsb3llZAo=') | b64decode | string }}"
|
||||
when: submodules_versioncheck|bool
|
||||
when: submodules_versioncheck | bool
|
||||
|
||||
- name: Print locale role version
|
||||
ansible.builtin.debug:
|
||||
msg: "Local role version: '{{ playbook_version_number|string }}'."
|
||||
when: submodules_versioncheck|bool
|
||||
msg: "Local role version: '{{ playbook_version_number | string }}'."
|
||||
when: submodules_versioncheck | bool
|
||||
|
||||
- name: Check if your version is outdated
|
||||
ansible.builtin.fail:
|
||||
msg: "Your ansible module has the version '{{ playbook_version_number }}' and is outdated. You need to update it!"
|
||||
when:
|
||||
- playbook_version.content|default("Mgo=")|b64decode|int - 1 >= playbook_version_number|int and submodules_versioncheck|bool
|
||||
- playbook_version.content|default("Mgo=")|b64decode|int - 1 >= playbook_version_number|int and submodules_versioncheck | bool
|
||||
|
||||
- name: write new version to remote disk
|
||||
- name: Write new version to remote disk
|
||||
become: true
|
||||
ansible.builtin.copy:
|
||||
content: "{{ playbook_version_number }}"
|
||||
dest: "/etc/.ansible-version/{{ playbook_version_path }}"
|
||||
mode: '0644'
|
||||
when: submodules_versioncheck|bool
|
||||
when: submodules_versioncheck | bool
|
||||
tags: skip_ansible_lint_template-instead-of-copy
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
# /etc/nsswitch.conf
|
||||
# {{ ansible_managed }}
|
||||
#
|
||||
# See https://galaxy.ansible.com/l3d/avahi_client and
|
||||
# https://galaxy.ansible.com/l3d/avahi for more details
|
||||
#
|
||||
# Example configuration of GNU Name Service Switch functionality.
|
||||
# If you have the `glibc-doc-reference' and `info' packages installed, try:
|
||||
# `info libc "Name Service Switch"' for information about this file.
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
---
|
||||
# versionscheck
|
||||
playbook_version_number: 7
|
||||
playbook_version_number: 8
|
||||
playbook_version_path: 'do1jlr.avahi_client.version'
|
||||
|
|
Loading…
Reference in a new issue