Update task names capitalization (#35)

This commit is contained in:
Vitaly 2023-03-10 13:45:00 +08:00 committed by GitHub
parent f75c25fe6a
commit 3b0666a60b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 33 additions and 33 deletions

View File

@ -1,19 +1,19 @@
---
# user and group creation
- name: Configure User Groups
- name: Configure user groups
ansible.builtin.import_tasks: install/user-group.yaml
# directory creation
- name: Configure Directories
- name: Configure directories
ansible.builtin.import_tasks: install/directories.yaml
# download and install agent
- name: Download and Install Agent
- name: Download and install Grafana Agent
ansible.builtin.import_tasks: install/download-install.yaml
when: (grafana_agent_local_binary_file is not defined) or (grafana_agent_local_binary_file | length == 0)
# local install of agent
- name: Local Install of Agent
- name: Local install of Grafana Agent
ansible.builtin.import_tasks:
file: install/local-install.yaml
when: __grafana_agent_local_install

View File

@ -1,7 +1,7 @@
---
- name: Create Install Directories
- name: Create install directories
block:
- name: Create Grafana Agent Install Directory
- name: Create Grafana Agent install directory
ansible.builtin.file:
path: "{{ grafana_agent_install_dir }}"
state: directory
@ -9,7 +9,7 @@
group: "{{ grafana_agent_user_group }}"
mode: 0770
- name: Create Grafana Agent Conf Directory
- name: Create Grafana Agent conf directory
ansible.builtin.file:
path: "{{ grafana_agent_config_dir }}"
state: directory
@ -17,7 +17,7 @@
group: "{{ grafana_agent_user_group }}"
mode: 0770
- name: Create Grafana Agent Data Directory
- name: Create Grafana Agent data directory
ansible.builtin.file:
path: "{{ grafana_agent_data_dir }}"
state: directory

View File

@ -1,7 +1,7 @@
---
- name: Download Grafana Agent Binary to controller (localhost)
- name: Download Grafana Agent binary to controller (localhost)
block:
- name: Create Grafana Agent temp Directory
- name: Create Grafana Agent temp directory
become: false
ansible.builtin.file:
path: "{{ grafana_agent_local_tmp_dir }}"
@ -11,7 +11,7 @@
check_mode: false
run_once: true
- name: Download Grafana Agent Archive to local folder
- name: Download Grafana Agent archive to local folder
become: false
ansible.builtin.get_url:
url: "{{ _grafana_agent_download_url }}"

View File

@ -1,5 +1,5 @@
---
- name: Install from Local
- name: Install from local
block:
- name: "Propagate local binary {{ grafana_agent_local_binary_file }}"
ansible.builtin.copy:

View File

@ -1,5 +1,5 @@
---
- name: Grafana Agent Group Creation
- name: Grafana Agent group creation
block:
- name: "Check if the group exists ({{ grafana_agent_user_group }})"
ansible.builtin.getent:
@ -18,14 +18,14 @@
state: present
when: not __grafana_agent_user_group_exists and grafana_agent_user_group != 'root'
- name: Grafana Agent User Group Exists
- name: Grafana Agent user group exists
ansible.builtin.debug:
msg: |-
The user group \"{{ grafana_agent_user_group }}\" already exists and will not be modified,
if modifying permissions please perform a separate task
when: __grafana_agent_user_group_exists
- name: Grafana Agent User Creation
- name: Grafana Agent user creation
block:
- name: "Check if the user exists ({{ grafana_agent_user }})"
ansible.builtin.getent:
@ -48,7 +48,7 @@
createhome: "{{ grafana_agent_user_createhome }}"
when: not __grafana_agent_user_exists and grafana_agent_user != 'root'
- name: Grafana Agent User Exists
- name: Grafana Agent user exists
ansible.builtin.debug:
msg: |-
The user \"{{ grafana_agent_user }}\" already exists and will not be modified,

View File

@ -1,5 +1,5 @@
---
- name: Preflight Tasks
- name: Preflight tasks
ansible.builtin.include_tasks:
file: preflight.yaml
apply:
@ -13,7 +13,7 @@
- grafana_agent_configure
- grafana_agent_run
- name: Install Tasks
- name: Install tasks
ansible.builtin.include_tasks:
file: install.yaml
apply:
@ -24,7 +24,7 @@
- grafana_agent_install
when: __grafana_agent_do_install
- name: Configuration Tasks
- name: Configuration tasks
ansible.builtin.include_tasks:
file: configure.yaml
apply:
@ -34,7 +34,7 @@
tags:
- grafana_agent_configure
- name: Ensure Grafana Agent is Started and Enabled on Boot
- name: Ensure Grafana Agent is started and enabled on boot
become: true
ansible.builtin.systemd:
daemon_reload: true

View File

@ -1,14 +1,14 @@
---
- name: Preflight Variable Checks
- name: Preflight variable checks
ansible.builtin.import_tasks: preflight/vars.yaml
- name: Systemd Variable Checks
- name: Systemd variable checks
ansible.builtin.import_tasks: preflight/systemd.yaml
- name: Install Variable Checks
- name: Install variable checks
ansible.builtin.import_tasks: preflight/install.yaml
- name: Download Variable Checks
- name: Download variable checks
ansible.builtin.import_tasks: preflight/download.yaml
- name: Set whether or not to do the install
@ -16,6 +16,6 @@
__grafana_agent_do_install: >-
{{ not __grafana_agent_is_installed.stat.exists or __grafana_agent_installed_version is version_compare(grafana_agent_version, '<') }}
- name: Do Install
- name: Do install
ansible.builtin.debug:
var: __grafana_agent_do_install

View File

@ -1,8 +1,8 @@
---
- name: Get Grafana Agent Version from Github
- name: Get Grafana Agent version from Github
when: grafana_agent_version == 'latest' and not __grafana_agent_local_install
block:
- name: Get the latest published Grafana-Agent # noqa command-instead-of-module
- name: Get the latest published Grafana Agent # noqa command-instead-of-module
ansible.builtin.shell: |
curl -s https://api.github.com/repos/{{ _grafana_agent_github_org }}/{{ _grafana_agent_github_repo }}/releases/latest \
| grep -m 1 tag_name \
@ -13,7 +13,7 @@
become: false
register: _grafana_agent_version_request
- name: Set the Grafana Agent Version
- name: Set the Grafana Agent version
ansible.builtin.set_fact:
grafana_agent_version: "{{ _grafana_agent_version_request.stdout }}"
@ -21,11 +21,11 @@
ansible.builtin.debug:
var: grafana_agent_version
- name: Set the Grafana Agent Download URL
- name: Set the Grafana Agent download URL
ansible.builtin.set_fact:
_grafana_agent_download_url: |-
{{ _grafana_agent_base_download_url }}/v{{ grafana_agent_version }}/{{ _grafana_agent_download_archive_file }}
- name: Grafana Agent Download URL
- name: Grafana Agent download URL
ansible.builtin.debug:
var: _grafana_agent_download_url

View File

@ -49,7 +49,7 @@
ansible.builtin.debug:
var: __grafana_agent_is_installed.stat.exists
- name: Install Checks
- name: Install checks
when: __grafana_agent_is_installed.stat.exists and not __grafana_agent_local_install
block:
- name: Gather currently installed grafana-agent version from the host
@ -63,10 +63,10 @@
register: __grafana_agent_current_version_output
check_mode: false
- name: Set Grafana Agent Installed Version for the host
- name: Set Grafana Agent installed version for the host
ansible.builtin.set_fact:
__grafana_agent_installed_version: "{{ __grafana_agent_current_version_output.stdout }}"
- name: Grafana Agent Installed Version on host
- name: Grafana Agent installed version on host
ansible.builtin.debug:
var: __grafana_agent_installed_version