Adding docsite

This commit is contained in:
Ishan Jain 2022-08-16 10:56:25 +05:30
parent df93dc65d9
commit e2297ca64d
17 changed files with 5866 additions and 0 deletions

6
docs/.gitignore vendored Normal file
View File

@ -0,0 +1,6 @@
# Copyright (c) Ansible Project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
/temp-rst
/build

25
docs/build.sh Executable file
View File

@ -0,0 +1,25 @@
#!/usr/bin/env bash
# Copyright (c) Ansible Project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
set -e
cd /Users/ishanjain/grafana-ansible-collection/docs
# Create collection documentation into temporary directory
rm -rf temp-rst
mkdir -p temp-rst
antsibull-docs collection \
--use-current \
--no-use-html-blobs \
--breadcrumbs \
--indexes \
--dest-dir temp-rst \
grafana.grafana
# Copy collection documentation into source directory
rsync -cprv --delete-after temp-rst/collections/ rst/collections/
# Build Sphinx site
sphinx-build -M html rst build -c . -W --keep-going

43
docs/conf.py Normal file
View File

@ -0,0 +1,43 @@
# Copyright (c) Ansible Project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
# This file only contains a selection of the most common options. For a full list see the
# documentation:
# http://www.sphinx-doc.org/en/master/config
project = 'Ansible collections'
copyright = 'Ansible contributors'
title = 'Ansible Collections Documentation'
html_short_title = 'Ansible Collections Documentation'
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.intersphinx', 'sphinx_antsibull_ext']
pygments_style = 'ansible'
highlight_language = 'YAML+Jinja'
html_theme = 'sphinx_ansible_theme'
html_show_sphinx = False
display_version = False
html_use_smartypants = True
html_use_modindex = False
html_use_index = False
html_copy_source = False
intersphinx_mapping = {
'python': ('https://docs.python.org/2/', (None, '../python2.inv')),
'python3': ('https://docs.python.org/3/', (None, '../python3.inv')),
'jinja2': ('http://jinja.palletsprojects.com/', (None, '../jinja2.inv')),
'ansible_devel': ('https://docs.ansible.com/ansible/devel/', (None, '../ansible_devel.inv')),
# If you want references to resolve to a released Ansible version (say, `5`), uncomment and replace X by this version:
# 'ansibleX': ('https://docs.ansible.com/ansible/X/', (None, '../ansibleX.inv')),
}
default_role = 'any'
nitpicky = True

8
docs/requirements.txt Normal file
View File

@ -0,0 +1,8 @@
# Copyright (c) Ansible Project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
antsibull-docs >= 1.0.0, < 2.0.0
ansible-pygments
sphinx
sphinx-ansible-theme >= 0.9.0

View File

@ -0,0 +1,724 @@
.. Document meta
:orphan:
.. |antsibull-internal-nbsp| unicode:: 0xA0
:trim:
.. role:: ansible-attribute-support-label
.. role:: ansible-attribute-support-property
.. role:: ansible-attribute-support-full
.. role:: ansible-attribute-support-partial
.. role:: ansible-attribute-support-none
.. role:: ansible-attribute-support-na
.. role:: ansible-option-type
.. role:: ansible-option-elements
.. role:: ansible-option-required
.. role:: ansible-option-versionadded
.. role:: ansible-option-aliases
.. role:: ansible-option-choices
.. role:: ansible-option-choices-entry
.. role:: ansible-option-default
.. role:: ansible-option-default-bold
.. role:: ansible-option-configuration
.. role:: ansible-option-returned-bold
.. role:: ansible-option-sample-bold
.. Anchors
.. _ansible_collections.grafana.grafana.alert_contact_point_module:
.. Anchors: short name for ansible.builtin
.. Anchors: aliases
.. Title
grafana.grafana.alert_contact_point module -- Manage Alerting Contact points in Grafana
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
.. Collection note
.. note::
This module is part of the `grafana.grafana collection <https://galaxy.ansible.com/grafana/grafana>`_ (version 0.0.7).
You might already have this collection installed if you are using the ``ansible`` package.
It is not included in ``ansible-core``.
To check whether it is installed, run :code:`ansible-galaxy collection list`.
To install it, use: :code:`ansible-galaxy collection install grafana.grafana`.
To use it in a playbook, specify: :code:`grafana.grafana.alert_contact_point`.
.. version_added
.. versionadded:: 0.0.1 of grafana.grafana
.. contents::
:local:
:depth: 1
.. Deprecated
Synopsis
--------
.. Description
- Create, Update and delete Contact points using Ansible.
.. Aliases
.. Requirements
Requirements
------------
The below requirements are needed on the host that executes this module.
- requests >= 1.0.0
.. Options
Parameters
----------
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Parameter
- Comments
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-DisableResolveMessage"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__parameter-disableresolvemessage:
.. rst-class:: ansible-option-title
**DisableResolveMessage**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-DisableResolveMessage" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`boolean`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
When set to True, Disables the resolve message [OK] that is sent when alerting state returns to false
.. rst-class:: ansible-option-line
:ansible-option-choices:`Choices:`
- :ansible-option-default-bold:`no` :ansible-option-default:`← (default)`
- :ansible-option-choices-entry:`yes`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-grafana_api_key"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__parameter-grafana_api_key:
.. rst-class:: ansible-option-title
**grafana_api_key**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-grafana_api_key" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Grafana API Key used to authenticate with Grafana.
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-name"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__parameter-name:
.. rst-class:: ansible-option-title
**name**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-name" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the contact point
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-settings"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__parameter-settings:
.. rst-class:: ansible-option-title
**settings**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-settings" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`dictionary` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Contact point settings
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-stack_slug"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__parameter-stack_slug:
.. rst-class:: ansible-option-title
**stack_slug**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-stack_slug" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the Grafana Cloud stack to which the contact points will be added
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-state"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__parameter-state:
.. rst-class:: ansible-option-title
**state**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-state" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
State for the Grafana CLoud stack.
.. rst-class:: ansible-option-line
:ansible-option-choices:`Choices:`
- :ansible-option-default-bold:`present` :ansible-option-default:`← (default)`
- :ansible-option-choices-entry:`absent`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-type"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__parameter-type:
.. rst-class:: ansible-option-title
**type**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-type" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Contact point type
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-uid"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__parameter-uid:
.. rst-class:: ansible-option-title
**uid**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-uid" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Sets the UID of the Contact point.
.. raw:: html
</div>
.. Attributes
.. Notes
.. Seealso
.. Examples
Examples
--------
.. code-block:: yaml+jinja
- name: Create/Update Alerting contact point
grafana.grafana.alert_contact_point:
name: ops-email
uid: opsemail
type: email
settings: {
addresses: "ops@mydomain.com,devs@mydomain.com"
}
stack_slug: "{{ stack_slug }}"
grafana_api_key: "{{ grafana_api_key }}"
state: present
- name: Delete Alerting contact point
grafana.grafana.alert_contact_point:
name: ops-email
uid: opsemail
type: email
settings: {
addresses: "ops@mydomain.com,devs@mydomain.com"
}
stack_slug: "{{ stack_slug }}"
grafana_api_key: "{{ grafana_api_key }}"
state: absent
.. Facts
.. Return values
Return Values
-------------
Common return values are documented :ref:`here <common_return_values>`, the following are the fields unique to this module:
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Key
- Description
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__return-output:
.. rst-class:: ansible-option-title
**output**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`dictionary`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Dict object containing Contact point information information
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` On success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/disableResolveMessage"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__return-output/disableresolvemessage:
.. rst-class:: ansible-option-title
**disableResolveMessage**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/disableResolveMessage" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`boolean`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
When set to True, Disables the resolve message [OK] that is sent when alerting state returns to false
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/name"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__return-output/name:
.. rst-class:: ansible-option-title
**name**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/name" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The name for the contact point
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/settings"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__return-output/settings:
.. rst-class:: ansible-option-title
**settings**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/settings" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`dictionary`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
Contains contact point settings
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/type"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__return-output/type:
.. rst-class:: ansible-option-title
**type**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/type" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The type of contact point
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/uid"></div>
.. _ansible_collections.grafana.grafana.alert_contact_point_module__return-output/uid:
.. rst-class:: ansible-option-title
**uid**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/uid" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The UID for the contact point
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
.. Status (Presently only deprecated)
.. Authors
Authors
~~~~~~~
- Ishan Jain (@ishanjainn)
.. Extra links
Collection links
~~~~~~~~~~~~~~~~
.. raw:: html
<p class="ansible-links">
<a href="https://github.com/grafana/grafana-ansible-collection/issues" aria-role="button" target="_blank" rel="noopener external">Issue Tracker</a>
<a href="https://github.com/grafana/grafana-ansible-collection" aria-role="button" target="_blank" rel="noopener external">Repository (Sources)</a>
</p>
.. Parsing errors

View File

@ -0,0 +1,861 @@
.. Document meta
:orphan:
.. |antsibull-internal-nbsp| unicode:: 0xA0
:trim:
.. role:: ansible-attribute-support-label
.. role:: ansible-attribute-support-property
.. role:: ansible-attribute-support-full
.. role:: ansible-attribute-support-partial
.. role:: ansible-attribute-support-none
.. role:: ansible-attribute-support-na
.. role:: ansible-option-type
.. role:: ansible-option-elements
.. role:: ansible-option-required
.. role:: ansible-option-versionadded
.. role:: ansible-option-aliases
.. role:: ansible-option-choices
.. role:: ansible-option-choices-entry
.. role:: ansible-option-default
.. role:: ansible-option-default-bold
.. role:: ansible-option-configuration
.. role:: ansible-option-returned-bold
.. role:: ansible-option-sample-bold
.. Anchors
.. _ansible_collections.grafana.grafana.alert_notification_policy_module:
.. Anchors: short name for ansible.builtin
.. Anchors: aliases
.. Title
grafana.grafana.alert_notification_policy module -- Sets the notification policy tree in Grafana Alerting
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
.. Collection note
.. note::
This module is part of the `grafana.grafana collection <https://galaxy.ansible.com/grafana/grafana>`_ (version 0.0.7).
You might already have this collection installed if you are using the ``ansible`` package.
It is not included in ``ansible-core``.
To check whether it is installed, run :code:`ansible-galaxy collection list`.
To install it, use: :code:`ansible-galaxy collection install grafana.grafana`.
To use it in a playbook, specify: :code:`grafana.grafana.alert_notification_policy`.
.. version_added
.. versionadded:: 0.0.1 of grafana.grafana
.. contents::
:local:
:depth: 1
.. Deprecated
Synopsis
--------
.. Description
- Set the notification policy tree using Ansible
.. Aliases
.. Requirements
Requirements
------------
The below requirements are needed on the host that executes this module.
- requests >= 1.0.0
.. Options
Parameters
----------
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Parameter
- Comments
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-Continue"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__parameter-continue:
.. rst-class:: ansible-option-title
**Continue**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-Continue" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`boolean`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Continue matching subsequent sibling nodes if set to `True`.
.. rst-class:: ansible-option-line
:ansible-option-choices:`Choices:`
- :ansible-option-default-bold:`no` :ansible-option-default:`← (default)`
- :ansible-option-choices-entry:`yes`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-grafana_api_key"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__parameter-grafana_api_key:
.. rst-class:: ansible-option-title
**grafana_api_key**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-grafana_api_key" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Grafana API Key used to authenticate with Grafana.
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-groupByStr"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__parameter-groupbystr:
.. rst-class:: ansible-option-title
**groupByStr**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-groupByStr" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`list` / :ansible-option-elements:`elements=string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
List of string.
Group alerts when you receive a notification based on labels. If empty it will be inherited from the parent policy.
.. rst-class:: ansible-option-line
:ansible-option-default-bold:`Default:` :ansible-option-default:`[]`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-groupInterval"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__parameter-groupinterval:
.. rst-class:: ansible-option-title
**groupInterval**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-groupInterval" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
The wait time to send a batch of new alerts for that group after the first notification was sent. Inherited from the parent policy if empty.
.. rst-class:: ansible-option-line
:ansible-option-default-bold:`Default:` :ansible-option-default:`"5m"`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-groupWait"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__parameter-groupwait:
.. rst-class:: ansible-option-title
**groupWait**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-groupWait" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
The wait time until the initial notification is sent for a new group created by an incoming alert. Inherited from the parent policy if empty.
.. rst-class:: ansible-option-line
:ansible-option-default-bold:`Default:` :ansible-option-default:`"30s"`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-muteTimeIntervals"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__parameter-mutetimeintervals:
.. rst-class:: ansible-option-title
**muteTimeIntervals**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-muteTimeIntervals" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`list` / :ansible-option-elements:`elements=string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
List of string.
Add mute timing to policy
.. rst-class:: ansible-option-line
:ansible-option-default-bold:`Default:` :ansible-option-default:`[]`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-objectMatchers"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__parameter-objectmatchers:
.. rst-class:: ansible-option-title
**objectMatchers**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-objectMatchers" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`list` / :ansible-option-elements:`elements=dictionary`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Matchers is a slice of Matchers that is sortable, implements Stringer, and provides a Matches method to match a LabelSet.
.. rst-class:: ansible-option-line
:ansible-option-default-bold:`Default:` :ansible-option-default:`[]`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-repeatInterval"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__parameter-repeatinterval:
.. rst-class:: ansible-option-title
**repeatInterval**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-repeatInterval" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
The waiting time to resend an alert after they have successfully been sent.
.. rst-class:: ansible-option-line
:ansible-option-default-bold:`Default:` :ansible-option-default:`"4h"`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-root_policy_receiver"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__parameter-root_policy_receiver:
.. rst-class:: ansible-option-title
**root_policy_receiver**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-root_policy_receiver" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the contact point to set as the default receiver
.. rst-class:: ansible-option-line
:ansible-option-default-bold:`Default:` :ansible-option-default:`"grafana-default-email"`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-routes"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__parameter-routes:
.. rst-class:: ansible-option-title
**routes**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-routes" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`list` / :ansible-option-elements:`elements=dictionary` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
List of objects
A Route is a node that contains definitions of how to handle alerts.
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-stack_slug"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__parameter-stack_slug:
.. rst-class:: ansible-option-title
**stack_slug**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-stack_slug" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the Grafana Cloud stack to which the notification policies will be added
.. raw:: html
</div>
.. Attributes
.. Notes
.. Seealso
.. Examples
Examples
--------
.. code-block:: yaml+jinja
- name: Set Notification policy tree
grafana.grafana.alert_notification_policy:
stack_slug: "{{ stack_slug }}"
grafana_api_key: "{{ grafana_api_key }}"
routes: [
{
receiver: myReceiver,
object_matchers: [["env", "=", "Production"]],
}
]
- name: Set nested Notification policies
grafana.grafana.alert_notification_policy:
routes: [
{
receiver: myReceiver,
object_matchers: [["env", "=", "Production"],["team", "=", "ops"]],
routes: [
{
receiver: myReceiver2,
object_matchers: [["region", "=", "eu"]],
}
]
},
{
receiver: myReceiver3,
object_matchers: [["env", "=", "Staging"]]
}
]
stack_slug: "{{ stack_slug }}"
grafana_api_key: "{{ grafana_api_key }}"
.. Facts
.. Return values
Return Values
-------------
Common return values are documented :ref:`here <common_return_values>`, the following are the fields unique to this module:
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Key
- Description
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__return-output:
.. rst-class:: ansible-option-title
**output**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`dictionary`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Dict object containing Notification tree information
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` On success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/group_interval"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__return-output/group_interval:
.. rst-class:: ansible-option-title
**group_interval**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/group_interval" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The waiting time to send a batch of new alerts for that group after the first notification was sent. This is of the parent policy.
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/group_wait"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__return-output/group_wait:
.. rst-class:: ansible-option-title
**group_wait**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/group_wait" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The waiting time until the initial notification is sent for a new group created by an incoming alert. This is of the parent policy.
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/receiver"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__return-output/receiver:
.. rst-class:: ansible-option-title
**receiver**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/receiver" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The name of the default contact point
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/repeat_interval"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__return-output/repeat_interval:
.. rst-class:: ansible-option-title
**repeat_interval**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/repeat_interval" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The waiting time to resend an alert after they have successfully been sent. This is of the parent policy
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/routes"></div>
.. _ansible_collections.grafana.grafana.alert_notification_policy_module__return-output/routes:
.. rst-class:: ansible-option-title
**routes**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/routes" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`list` / :ansible-option-elements:`elements=string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The entire notification tree returned as a list
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` on success
.. raw:: html
</div>
.. Status (Presently only deprecated)
.. Authors
Authors
~~~~~~~
- Ishan Jain (@ishanjainn)
.. Extra links
Collection links
~~~~~~~~~~~~~~~~
.. raw:: html
<p class="ansible-links">
<a href="https://github.com/grafana/grafana-ansible-collection/issues" aria-role="button" target="_blank" rel="noopener external">Issue Tracker</a>
<a href="https://github.com/grafana/grafana-ansible-collection" aria-role="button" target="_blank" rel="noopener external">Repository (Sources)</a>
</p>
.. Parsing errors

View File

@ -0,0 +1,402 @@
.. Document meta
:orphan:
.. |antsibull-internal-nbsp| unicode:: 0xA0
:trim:
.. role:: ansible-attribute-support-label
.. role:: ansible-attribute-support-property
.. role:: ansible-attribute-support-full
.. role:: ansible-attribute-support-partial
.. role:: ansible-attribute-support-none
.. role:: ansible-attribute-support-na
.. role:: ansible-option-type
.. role:: ansible-option-elements
.. role:: ansible-option-required
.. role:: ansible-option-versionadded
.. role:: ansible-option-aliases
.. role:: ansible-option-choices
.. role:: ansible-option-choices-entry
.. role:: ansible-option-default
.. role:: ansible-option-default-bold
.. role:: ansible-option-configuration
.. role:: ansible-option-returned-bold
.. role:: ansible-option-sample-bold
.. Anchors
.. _ansible_collections.grafana.grafana.cloud_api_key_module:
.. Anchors: short name for ansible.builtin
.. Anchors: aliases
.. Title
grafana.grafana.cloud_api_key module -- Manage Grafana Cloud API keys
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
.. Collection note
.. note::
This module is part of the `grafana.grafana collection <https://galaxy.ansible.com/grafana/grafana>`_ (version 0.0.7).
You might already have this collection installed if you are using the ``ansible`` package.
It is not included in ``ansible-core``.
To check whether it is installed, run :code:`ansible-galaxy collection list`.
To install it, use: :code:`ansible-galaxy collection install grafana.grafana`.
To use it in a playbook, specify: :code:`grafana.grafana.cloud_api_key`.
.. version_added
.. versionadded:: 0.0.1 of grafana.grafana
.. contents::
:local:
:depth: 1
.. Deprecated
Synopsis
--------
.. Description
- Create and delete Grafana Cloud API keys using Ansible.
.. Aliases
.. Requirements
Requirements
------------
The below requirements are needed on the host that executes this module.
- requests >= 1.0.0
.. Options
Parameters
----------
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Parameter
- Comments
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-existing_cloud_api_key"></div>
.. _ansible_collections.grafana.grafana.cloud_api_key_module__parameter-existing_cloud_api_key:
.. rst-class:: ansible-option-title
**existing_cloud_api_key**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-existing_cloud_api_key" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
CLoud API Key to authenticate with Grafana Cloud.
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-fail_if_already_created"></div>
.. _ansible_collections.grafana.grafana.cloud_api_key_module__parameter-fail_if_already_created:
.. rst-class:: ansible-option-title
**fail_if_already_created**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-fail_if_already_created" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`boolean`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
If set to True, the task will fail if the API key with same name already exists in the Organization.
.. rst-class:: ansible-option-line
:ansible-option-choices:`Choices:`
- :ansible-option-choices-entry:`no`
- :ansible-option-default-bold:`yes` :ansible-option-default:`← (default)`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-name"></div>
.. _ansible_collections.grafana.grafana.cloud_api_key_module__parameter-name:
.. rst-class:: ansible-option-title
**name**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-name" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the Grafana Cloud API key.
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-org_slug"></div>
.. _ansible_collections.grafana.grafana.cloud_api_key_module__parameter-org_slug:
.. rst-class:: ansible-option-title
**org_slug**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-org_slug" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the Grafana Cloud organization in which Cloud API key will be created
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-role"></div>
.. _ansible_collections.grafana.grafana.cloud_api_key_module__parameter-role:
.. rst-class:: ansible-option-title
**role**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-role" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Role to be associated with the CLoud API key.
.. rst-class:: ansible-option-line
:ansible-option-choices:`Choices:`
- :ansible-option-choices-entry:`Admin`
- :ansible-option-choices-entry:`Viewer`
- :ansible-option-choices-entry:`Editor`
- :ansible-option-choices-entry:`MetricsPublisher`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-state"></div>
.. _ansible_collections.grafana.grafana.cloud_api_key_module__parameter-state:
.. rst-class:: ansible-option-title
**state**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-state" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
State for the Grafana CLoud stack.
.. rst-class:: ansible-option-line
:ansible-option-choices:`Choices:`
- :ansible-option-default-bold:`present` :ansible-option-default:`← (default)`
- :ansible-option-choices-entry:`absent`
.. raw:: html
</div>
.. Attributes
.. Notes
.. Seealso
.. Examples
Examples
--------
.. code-block:: yaml+jinja
- name: Create Grafana Cloud API key
grafana.grafana.cloud_api_key:
name: key_name
role: Admin
org_slug: "{{ org_slug }}"
existing_cloud_api_key: "{{ grafana_cloud_api_key }}"
fail_if_already_created: False
state: present
- name: Delete Grafana Cloud API key
grafana.grafana.cloud_api_key:
name: key_name
org_slug: "{{ org_slug }}"
existing_cloud_api_key: "{{ grafana_cloud_api_key }}"
state: absent
.. Facts
.. Return values
.. Status (Presently only deprecated)
.. Authors
Authors
~~~~~~~
- Ishan Jain (@ishanjainn)
.. Extra links
Collection links
~~~~~~~~~~~~~~~~
.. raw:: html
<p class="ansible-links">
<a href="https://github.com/grafana/grafana-ansible-collection/issues" aria-role="button" target="_blank" rel="noopener external">Issue Tracker</a>
<a href="https://github.com/grafana/grafana-ansible-collection" aria-role="button" target="_blank" rel="noopener external">Repository (Sources)</a>
</p>
.. Parsing errors

View File

@ -0,0 +1,569 @@
.. Document meta
:orphan:
.. |antsibull-internal-nbsp| unicode:: 0xA0
:trim:
.. role:: ansible-attribute-support-label
.. role:: ansible-attribute-support-property
.. role:: ansible-attribute-support-full
.. role:: ansible-attribute-support-partial
.. role:: ansible-attribute-support-none
.. role:: ansible-attribute-support-na
.. role:: ansible-option-type
.. role:: ansible-option-elements
.. role:: ansible-option-required
.. role:: ansible-option-versionadded
.. role:: ansible-option-aliases
.. role:: ansible-option-choices
.. role:: ansible-option-choices-entry
.. role:: ansible-option-default
.. role:: ansible-option-default-bold
.. role:: ansible-option-configuration
.. role:: ansible-option-returned-bold
.. role:: ansible-option-sample-bold
.. Anchors
.. _ansible_collections.grafana.grafana.cloud_plugin_module:
.. Anchors: short name for ansible.builtin
.. Anchors: aliases
.. Title
grafana.grafana.cloud_plugin module -- Manage Grafana Cloud Plugins
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
.. Collection note
.. note::
This module is part of the `grafana.grafana collection <https://galaxy.ansible.com/grafana/grafana>`_ (version 0.0.7).
You might already have this collection installed if you are using the ``ansible`` package.
It is not included in ``ansible-core``.
To check whether it is installed, run :code:`ansible-galaxy collection list`.
To install it, use: :code:`ansible-galaxy collection install grafana.grafana`.
To use it in a playbook, specify: :code:`grafana.grafana.cloud_plugin`.
.. version_added
.. versionadded:: 0.0.1 of grafana.grafana
.. contents::
:local:
:depth: 1
.. Deprecated
Synopsis
--------
.. Description
- Create, Update and delete Grafana Cloud stacks using Ansible.
.. Aliases
.. Requirements
Requirements
------------
The below requirements are needed on the host that executes this module.
- requests >= 1.0.0
.. Options
Parameters
----------
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Parameter
- Comments
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-cloud_api_key"></div>
.. _ansible_collections.grafana.grafana.cloud_plugin_module__parameter-cloud_api_key:
.. rst-class:: ansible-option-title
**cloud_api_key**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-cloud_api_key" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
CLoud API Key to authenticate with Grafana Cloud.
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-name"></div>
.. _ansible_collections.grafana.grafana.cloud_plugin_module__parameter-name:
.. rst-class:: ansible-option-title
**name**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-name" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the plugin, e.g. grafana-github-datasource .
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-stack_slug"></div>
.. _ansible_collections.grafana.grafana.cloud_plugin_module__parameter-stack_slug:
.. rst-class:: ansible-option-title
**stack_slug**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-stack_slug" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the Grafana Cloud stack to which the plugin will be added
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-state"></div>
.. _ansible_collections.grafana.grafana.cloud_plugin_module__parameter-state:
.. rst-class:: ansible-option-title
**state**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-state" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
State for the Grafana CLoud stack.
.. rst-class:: ansible-option-line
:ansible-option-choices:`Choices:`
- :ansible-option-default-bold:`present` :ansible-option-default:`← (default)`
- :ansible-option-choices-entry:`absent`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-version"></div>
.. _ansible_collections.grafana.grafana.cloud_plugin_module__parameter-version:
.. rst-class:: ansible-option-title
**version**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-version" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Version of the plugin to install. Defaults to latest.
.. rst-class:: ansible-option-line
:ansible-option-default-bold:`Default:` :ansible-option-default:`"latest"`
.. raw:: html
</div>
.. Attributes
.. Notes
.. Seealso
.. Examples
Examples
--------
.. code-block:: yaml+jinja
- name: Create/Update a plugin
grafana.grafana.cloud_plugin:
name: grafana-github-datasource
version: 1.0.14
stack_slug: "{{ stack_slug }}"
cloud_api_key: "{{ grafana_cloud_api_key }}"
state: present
- name: Delete a Grafana Cloud stack
grafana.grafana.cloud_plugin:
name: grafana-github-datasource
stack_slug: "{{ stack_slug }}"
cloud_api_key: "{{ grafana_cloud_api_key }}"
state: absent
.. Facts
.. Return values
Return Values
-------------
Common return values are documented :ref:`here <common_return_values>`, the following are the fields unique to this module:
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Key
- Description
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-current_version"></div>
.. _ansible_collections.grafana.grafana.cloud_plugin_module__return-current_version:
.. rst-class:: ansible-option-title
**current_version**
.. raw:: html
<a class="ansibleOptionLink" href="#return-current_version" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Current version of the plugin
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` On success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-latest_version"></div>
.. _ansible_collections.grafana.grafana.cloud_plugin_module__return-latest_version:
.. rst-class:: ansible-option-title
**latest_version**
.. raw:: html
<a class="ansibleOptionLink" href="#return-latest_version" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Latest version available for the plugin
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` On success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-pluginId"></div>
.. _ansible_collections.grafana.grafana.cloud_plugin_module__return-pluginid:
.. rst-class:: ansible-option-title
**pluginId**
.. raw:: html
<a class="ansibleOptionLink" href="#return-pluginId" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`integer`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Id for the Plugin
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` On success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-pluginName"></div>
.. _ansible_collections.grafana.grafana.cloud_plugin_module__return-pluginname:
.. rst-class:: ansible-option-title
**pluginName**
.. raw:: html
<a class="ansibleOptionLink" href="#return-pluginName" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the plugin
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` On success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-pluginSlug"></div>
.. _ansible_collections.grafana.grafana.cloud_plugin_module__return-pluginslug:
.. rst-class:: ansible-option-title
**pluginSlug**
.. raw:: html
<a class="ansibleOptionLink" href="#return-pluginSlug" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Slug for the Plugin
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` On success
.. raw:: html
</div>
.. Status (Presently only deprecated)
.. Authors
Authors
~~~~~~~
- Ishan Jain (@ishanjainn)
.. Extra links
Collection links
~~~~~~~~~~~~~~~~
.. raw:: html
<p class="ansible-links">
<a href="https://github.com/grafana/grafana-ansible-collection/issues" aria-role="button" target="_blank" rel="noopener external">Issue Tracker</a>
<a href="https://github.com/grafana/grafana-ansible-collection" aria-role="button" target="_blank" rel="noopener external">Repository (Sources)</a>
</p>
.. Parsing errors

View File

@ -0,0 +1,807 @@
.. Document meta
:orphan:
.. |antsibull-internal-nbsp| unicode:: 0xA0
:trim:
.. role:: ansible-attribute-support-label
.. role:: ansible-attribute-support-property
.. role:: ansible-attribute-support-full
.. role:: ansible-attribute-support-partial
.. role:: ansible-attribute-support-none
.. role:: ansible-attribute-support-na
.. role:: ansible-option-type
.. role:: ansible-option-elements
.. role:: ansible-option-required
.. role:: ansible-option-versionadded
.. role:: ansible-option-aliases
.. role:: ansible-option-choices
.. role:: ansible-option-choices-entry
.. role:: ansible-option-default
.. role:: ansible-option-default-bold
.. role:: ansible-option-configuration
.. role:: ansible-option-returned-bold
.. role:: ansible-option-sample-bold
.. Anchors
.. _ansible_collections.grafana.grafana.cloud_stack_module:
.. Anchors: short name for ansible.builtin
.. Anchors: aliases
.. Title
grafana.grafana.cloud_stack module -- Manage Grafana Cloud stack
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
.. Collection note
.. note::
This module is part of the `grafana.grafana collection <https://galaxy.ansible.com/grafana/grafana>`_ (version 0.0.7).
You might already have this collection installed if you are using the ``ansible`` package.
It is not included in ``ansible-core``.
To check whether it is installed, run :code:`ansible-galaxy collection list`.
To install it, use: :code:`ansible-galaxy collection install grafana.grafana`.
To use it in a playbook, specify: :code:`grafana.grafana.cloud_stack`.
.. version_added
.. versionadded:: 0.0.1 of grafana.grafana
.. contents::
:local:
:depth: 1
.. Deprecated
Synopsis
--------
.. Description
- Create and delete Grafana Cloud stacks using Ansible.
.. Aliases
.. Requirements
Requirements
------------
The below requirements are needed on the host that executes this module.
- requests >= 1.0.0
.. Options
Parameters
----------
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Parameter
- Comments
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-cloud_api_key"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__parameter-cloud_api_key:
.. rst-class:: ansible-option-title
**cloud_api_key**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-cloud_api_key" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
CLoud API Key to authenticate with Grafana Cloud.
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-name"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__parameter-name:
.. rst-class:: ansible-option-title
**name**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-name" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of stack. Conventionally matches the URL of the instance. For example, "<stack_slug>.grafana.net".
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-org_slug"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__parameter-org_slug:
.. rst-class:: ansible-option-title
**org_slug**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-org_slug" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the organization under which Cloud stack is created.
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-region"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__parameter-region:
.. rst-class:: ansible-option-title
**region**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-region" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Choose a region for your stack.
.. rst-class:: ansible-option-line
:ansible-option-choices:`Choices:`
- :ansible-option-default-bold:`us` :ansible-option-default:`← (default)`
- :ansible-option-choices-entry:`us-azure`
- :ansible-option-choices-entry:`eu`
- :ansible-option-choices-entry:`au`
- :ansible-option-choices-entry:`eu-azure`
- :ansible-option-choices-entry:`prod-ap-southeast-0`
- :ansible-option-choices-entry:`prod-gb-south-0`
- :ansible-option-choices-entry:`prod-eu-west-3`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-stack_slug"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__parameter-stack_slug:
.. rst-class:: ansible-option-title
**stack_slug**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-stack_slug" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Subdomain of the Grafana instance. For example, if slug is <stack_slug>, the instance URL will be https://<stack_slug>.grafana.net
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-state"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__parameter-state:
.. rst-class:: ansible-option-title
**state**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-state" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
State for the Grafana CLoud stack.
.. rst-class:: ansible-option-line
:ansible-option-choices:`Choices:`
- :ansible-option-default-bold:`present` :ansible-option-default:`← (default)`
- :ansible-option-choices-entry:`absent`
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-url"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__parameter-url:
.. rst-class:: ansible-option-title
**url**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-url" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
If you use a custom domain for the instance, you can provide it here. Will be set to https://<stack_slug>.grafana.net if not provided.
.. raw:: html
</div>
.. Attributes
.. Notes
.. Seealso
.. Examples
Examples
--------
.. code-block:: yaml+jinja
- name: Create a Grafana Cloud stack
grafana.grafana.cloud_stack:
name: company_name
slug: company_name
cloud_api_key: "{{ grafana_cloud_api_key }}"
region: eu
url: https://grafana.company_name.com
state: present
- name: Delete a Grafana Cloud stack
grafana.grafana.cloud_stack:
name: company_name
slug: company_name
cloud_api_key: "{{ grafana_cloud_api_key }}"
state: absent
.. Facts
.. Return values
Return Values
-------------
Common return values are documented :ref:`here <common_return_values>`, the following are the fields unique to this module:
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Key
- Description
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-alertmanager_name"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__return-alertmanager_name:
.. rst-class:: ansible-option-title
**alertmanager_name**
.. raw:: html
<a class="ansibleOptionLink" href="#return-alertmanager_name" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the alertmanager instance
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` always
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-alertmanager_url"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__return-alertmanager_url:
.. rst-class:: ansible-option-title
**alertmanager_url**
.. raw:: html
<a class="ansibleOptionLink" href="#return-alertmanager_url" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
URL of the alertmanager instance
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` always
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-cluster_slug"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__return-cluster_slug:
.. rst-class:: ansible-option-title
**cluster_slug**
.. raw:: html
<a class="ansibleOptionLink" href="#return-cluster_slug" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Slug for the cluster where the Grafana stack is deployed
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` always
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-id"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__return-id:
.. rst-class:: ansible-option-title
**id**
.. raw:: html
<a class="ansibleOptionLink" href="#return-id" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`integer`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
ID of the Grafana Cloud stack
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` always
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-loki_url"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__return-loki_url:
.. rst-class:: ansible-option-title
**loki_url**
.. raw:: html
<a class="ansibleOptionLink" href="#return-loki_url" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
URl for the Loki instance
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` always
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-orgID"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__return-orgid:
.. rst-class:: ansible-option-title
**orgID**
.. raw:: html
<a class="ansibleOptionLink" href="#return-orgID" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`integer`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
ID of the Grafana Cloud organization
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` always
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-prometheus_url"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__return-prometheus_url:
.. rst-class:: ansible-option-title
**prometheus_url**
.. raw:: html
<a class="ansibleOptionLink" href="#return-prometheus_url" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
URl for the Prometheus instance
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` always
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-tempo_url"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__return-tempo_url:
.. rst-class:: ansible-option-title
**tempo_url**
.. raw:: html
<a class="ansibleOptionLink" href="#return-tempo_url" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
URl for the Tempo instance
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` always
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-url"></div>
.. _ansible_collections.grafana.grafana.cloud_stack_module__return-url:
.. rst-class:: ansible-option-title
**url**
.. raw:: html
<a class="ansibleOptionLink" href="#return-url" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
URL of the Grafana Cloud stack
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` always
.. raw:: html
</div>
.. Status (Presently only deprecated)
.. Authors
Authors
~~~~~~~
- Ishan Jain (@ishanjainn)
.. Extra links
Collection links
~~~~~~~~~~~~~~~~
.. raw:: html
<p class="ansible-links">
<a href="https://github.com/grafana/grafana-ansible-collection/issues" aria-role="button" target="_blank" rel="noopener external">Issue Tracker</a>
<a href="https://github.com/grafana/grafana-ansible-collection" aria-role="button" target="_blank" rel="noopener external">Repository (Sources)</a>
</p>
.. Parsing errors

View File

@ -0,0 +1,691 @@
.. Document meta
:orphan:
.. |antsibull-internal-nbsp| unicode:: 0xA0
:trim:
.. role:: ansible-attribute-support-label
.. role:: ansible-attribute-support-property
.. role:: ansible-attribute-support-full
.. role:: ansible-attribute-support-partial
.. role:: ansible-attribute-support-none
.. role:: ansible-attribute-support-na
.. role:: ansible-option-type
.. role:: ansible-option-elements
.. role:: ansible-option-required
.. role:: ansible-option-versionadded
.. role:: ansible-option-aliases
.. role:: ansible-option-choices
.. role:: ansible-option-choices-entry
.. role:: ansible-option-default
.. role:: ansible-option-default-bold
.. role:: ansible-option-configuration
.. role:: ansible-option-returned-bold
.. role:: ansible-option-sample-bold
.. Anchors
.. _ansible_collections.grafana.grafana.dashboard_module:
.. Anchors: short name for ansible.builtin
.. Anchors: aliases
.. Title
grafana.grafana.dashboard module -- Manage Dashboards in Grafana
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
.. Collection note
.. note::
This module is part of the `grafana.grafana collection <https://galaxy.ansible.com/grafana/grafana>`_ (version 0.0.7).
You might already have this collection installed if you are using the ``ansible`` package.
It is not included in ``ansible-core``.
To check whether it is installed, run :code:`ansible-galaxy collection list`.
To install it, use: :code:`ansible-galaxy collection install grafana.grafana`.
To use it in a playbook, specify: :code:`grafana.grafana.dashboard`.
.. version_added
.. versionadded:: 0.0.1 of grafana.grafana
.. contents::
:local:
:depth: 1
.. Deprecated
Synopsis
--------
.. Description
- Create, Update and delete Dashboards using Ansible.
.. Aliases
.. Requirements
Requirements
------------
The below requirements are needed on the host that executes this module.
- requests >= 1.0.0
.. Options
Parameters
----------
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Parameter
- Comments
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-dashboard"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__parameter-dashboard:
.. rst-class:: ansible-option-title
**dashboard**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-dashboard" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`dictionary` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
JSON source code for dashboard
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-grafana_api_key"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__parameter-grafana_api_key:
.. rst-class:: ansible-option-title
**grafana_api_key**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-grafana_api_key" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
CLoud API Key to authenticate with Grafana Cloud.
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-stack_slug"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__parameter-stack_slug:
.. rst-class:: ansible-option-title
**stack_slug**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-stack_slug" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the Grafana Cloud stack to which the dashboard will be added
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-state"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__parameter-state:
.. rst-class:: ansible-option-title
**state**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-state" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
State for the Grafana CLoud stack.
.. rst-class:: ansible-option-line
:ansible-option-choices:`Choices:`
- :ansible-option-default-bold:`present` :ansible-option-default:`← (default)`
- :ansible-option-choices-entry:`absent`
.. raw:: html
</div>
.. Attributes
.. Notes
.. Seealso
.. Examples
Examples
--------
.. code-block:: yaml+jinja
- name: Create/Update a dashboard
grafana.grafana.dashboard:
datasource: "{{ lookup('ansible.builtin.file', 'dashboard.json') }}"
stack_slug: "{{ stack_slug }}"
grafana_api_key: "{{ grafana_api_key }}"
state: present
- name: Delete dashboard
grafana.grafana.dashboard:
datasource: "{{ lookup('ansible.builtin.file', 'dashboard.json') }}"
stack_slug: "{{ stack_slug }}"
grafana_api_key: "{{ grafana_api_key }}"
state: absent
.. Facts
.. Return values
Return Values
-------------
Common return values are documented :ref:`here <common_return_values>`, the following are the fields unique to this module:
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Key
- Description
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__return-output:
.. rst-class:: ansible-option-title
**output**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`dictionary`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Dict object containing folder information
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` On success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/id"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__return-output/id:
.. rst-class:: ansible-option-title
**id**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/id" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`integer`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The ID for the dashboard
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/message"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__return-output/message:
.. rst-class:: ansible-option-title
**message**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/message" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The message returned after the operation on the dashboard
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is absent and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/slug"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__return-output/slug:
.. rst-class:: ansible-option-title
**slug**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/slug" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The slug for the dashboard
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/status"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__return-output/status:
.. rst-class:: ansible-option-title
**status**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/status" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The status of the dashboard
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/title"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__return-output/title:
.. rst-class:: ansible-option-title
**title**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/title" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The name of the dashboard
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is absent and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/uid"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__return-output/uid:
.. rst-class:: ansible-option-title
**uid**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/uid" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The UID for the dashboard
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/url"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__return-output/url:
.. rst-class:: ansible-option-title
**url**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/url" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The endpoint for the dashboard
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/version"></div>
.. _ansible_collections.grafana.grafana.dashboard_module__return-output/version:
.. rst-class:: ansible-option-title
**version**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/version" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`integer`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The version of the dashboard
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
.. Status (Presently only deprecated)
.. Authors
Authors
~~~~~~~
- Ishan Jain (@ishanjainn)
.. Extra links
Collection links
~~~~~~~~~~~~~~~~
.. raw:: html
<p class="ansible-links">
<a href="https://github.com/grafana/grafana-ansible-collection/issues" aria-role="button" target="_blank" rel="noopener external">Issue Tracker</a>
<a href="https://github.com/grafana/grafana-ansible-collection" aria-role="button" target="_blank" rel="noopener external">Repository (Sources)</a>
</p>
.. Parsing errors

View File

@ -0,0 +1,531 @@
.. Document meta
:orphan:
.. |antsibull-internal-nbsp| unicode:: 0xA0
:trim:
.. role:: ansible-attribute-support-label
.. role:: ansible-attribute-support-property
.. role:: ansible-attribute-support-full
.. role:: ansible-attribute-support-partial
.. role:: ansible-attribute-support-none
.. role:: ansible-attribute-support-na
.. role:: ansible-option-type
.. role:: ansible-option-elements
.. role:: ansible-option-required
.. role:: ansible-option-versionadded
.. role:: ansible-option-aliases
.. role:: ansible-option-choices
.. role:: ansible-option-choices-entry
.. role:: ansible-option-default
.. role:: ansible-option-default-bold
.. role:: ansible-option-configuration
.. role:: ansible-option-returned-bold
.. role:: ansible-option-sample-bold
.. Anchors
.. _ansible_collections.grafana.grafana.datasource_module:
.. Anchors: short name for ansible.builtin
.. Anchors: aliases
.. Title
grafana.grafana.datasource module -- Manage Data sources in Grafana
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
.. Collection note
.. note::
This module is part of the `grafana.grafana collection <https://galaxy.ansible.com/grafana/grafana>`_ (version 0.0.7).
You might already have this collection installed if you are using the ``ansible`` package.
It is not included in ``ansible-core``.
To check whether it is installed, run :code:`ansible-galaxy collection list`.
To install it, use: :code:`ansible-galaxy collection install grafana.grafana`.
To use it in a playbook, specify: :code:`grafana.grafana.datasource`.
.. version_added
.. versionadded:: 0.0.1 of grafana.grafana
.. contents::
:local:
:depth: 1
.. Deprecated
Synopsis
--------
.. Description
- Create, Update and delete Data sources using Ansible.
.. Aliases
.. Requirements
Requirements
------------
The below requirements are needed on the host that executes this module.
- requests >= 1.0.0
.. Options
Parameters
----------
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Parameter
- Comments
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-datasource"></div>
.. _ansible_collections.grafana.grafana.datasource_module__parameter-datasource:
.. rst-class:: ansible-option-title
**datasource**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-datasource" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`dictionary` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
JSON source code for the Data source
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-grafana_api_key"></div>
.. _ansible_collections.grafana.grafana.datasource_module__parameter-grafana_api_key:
.. rst-class:: ansible-option-title
**grafana_api_key**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-grafana_api_key" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
CLoud API Key to authenticate with Grafana Cloud.
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-stack_slug"></div>
.. _ansible_collections.grafana.grafana.datasource_module__parameter-stack_slug:
.. rst-class:: ansible-option-title
**stack_slug**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-stack_slug" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string` / :ansible-option-required:`required`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Name of the Grafana Cloud stack to which the data source will be added
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="parameter-state"></div>
.. _ansible_collections.grafana.grafana.datasource_module__parameter-state:
.. rst-class:: ansible-option-title
**state**
.. raw:: html
<a class="ansibleOptionLink" href="#parameter-state" title="Permalink to this option"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
State for the Grafana CLoud stack.
.. rst-class:: ansible-option-line
:ansible-option-choices:`Choices:`
- :ansible-option-default-bold:`present` :ansible-option-default:`← (default)`
- :ansible-option-choices-entry:`absent`
.. raw:: html
</div>
.. Attributes
.. Notes
.. Seealso
.. Examples
Examples
--------
.. code-block:: yaml+jinja
- name: Create/Update Data sources
grafana.grafana.datasource:
datasource: "{{ lookup('ansible.builtin.file', 'datasource.json') }}"
stack_slug: "{{ stack_slug }}"
grafana_api_key: "{{ grafana_api_key }}"
state: present
- name: Delete Data sources
grafana.grafana.datasource:
datasource: "{{ lookup('ansible.builtin.file', 'datasource.json') }}"
stack_slug: "{{ stack_slug }}"
grafana_api_key: "{{ grafana_api_key }}"
state: absent
.. Facts
.. Return values
Return Values
-------------
Common return values are documented :ref:`here <common_return_values>`, the following are the fields unique to this module:
.. rst-class:: ansible-option-table
.. list-table::
:width: 100%
:widths: auto
:header-rows: 1
* - Key
- Description
* - .. raw:: html
<div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output"></div>
.. _ansible_collections.grafana.grafana.datasource_module__return-output:
.. rst-class:: ansible-option-title
**output**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`dictionary`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-cell">
Dict object containing Data source information
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` On success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/datasource"></div>
.. _ansible_collections.grafana.grafana.datasource_module__return-output/datasource:
.. rst-class:: ansible-option-title
**datasource**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/datasource" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`dictionary`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The response body content for the data source configuration.
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/id"></div>
.. _ansible_collections.grafana.grafana.datasource_module__return-output/id:
.. rst-class:: ansible-option-title
**id**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/id" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`integer`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The ID assigned to the data source
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/message"></div>
.. _ansible_collections.grafana.grafana.datasource_module__return-output/message:
.. rst-class:: ansible-option-title
**message**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/message" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The message returned after the operation on the Data source
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` on success
.. raw:: html
</div>
* - .. raw:: html
<div class="ansible-option-indent"></div><div class="ansible-option-cell">
<div class="ansibleOptionAnchor" id="return-output/name"></div>
.. _ansible_collections.grafana.grafana.datasource_module__return-output/name:
.. rst-class:: ansible-option-title
**name**
.. raw:: html
<a class="ansibleOptionLink" href="#return-output/name" title="Permalink to this return value"></a>
.. rst-class:: ansible-option-type-line
:ansible-option-type:`string`
.. raw:: html
</div>
- .. raw:: html
<div class="ansible-option-indent-desc"></div><div class="ansible-option-cell">
The name of the data source defined in the JSON source code
.. rst-class:: ansible-option-line
:ansible-option-returned-bold:`Returned:` state is present and on success
.. raw:: html
</div>
.. Status (Presently only deprecated)
.. Authors
Authors
~~~~~~~
- Ishan Jain (@ishanjainn)
.. Extra links
Collection links
~~~~~~~~~~~~~~~~
.. raw:: html
<p class="ansible-links">
<a href="https://github.com/grafana/grafana-ansible-collection/issues" aria-role="button" target="_blank" rel="noopener external">Issue Tracker</a>
<a href="https://github.com/grafana/grafana-ansible-collection" aria-role="button" target="_blank" rel="noopener external">Repository (Sources)</a>
</p>
.. Parsing errors

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,73 @@
.. _plugins_in_grafana.grafana:
Grafana.Grafana
===============
Collection version 0.0.7
.. contents::
:local:
:depth: 1
Description
-----------
Ansible collection to manage Grafana resources
**Authors:**
* Grafana Labs <grafana.com>
* Ishan Jain <ishan.jain@grafana.com>
.. raw:: html
<p class="ansible-links">
<a href="https://github.com/grafana/grafana-ansible-collection/issues" aria-role="button" target="_blank" rel="noopener external">Issue Tracker</a>
<a href="https://github.com/grafana/grafana-ansible-collection" aria-role="button" target="_blank" rel="noopener external">Repository (Sources)</a>
</p>
.. toctree::
:maxdepth: 1
Plugin Index
------------
These are the plugins in the grafana.grafana collection:
Modules
~~~~~~~
* :ref:`alert_contact_point module <ansible_collections.grafana.grafana.alert_contact_point_module>` -- Manage Alerting Contact points in Grafana
* :ref:`alert_notification_policy module <ansible_collections.grafana.grafana.alert_notification_policy_module>` -- Sets the notification policy tree in Grafana Alerting
* :ref:`cloud_api_key module <ansible_collections.grafana.grafana.cloud_api_key_module>` -- Manage Grafana Cloud API keys
* :ref:`cloud_plugin module <ansible_collections.grafana.grafana.cloud_plugin_module>` -- Manage Grafana Cloud Plugins
* :ref:`cloud_stack module <ansible_collections.grafana.grafana.cloud_stack_module>` -- Manage Grafana Cloud stack
* :ref:`dashboard module <ansible_collections.grafana.grafana.dashboard_module>` -- Manage Dashboards in Grafana
* :ref:`datasource module <ansible_collections.grafana.grafana.datasource_module>` -- Manage Data sources in Grafana
* :ref:`folder module <ansible_collections.grafana.grafana.folder_module>` -- Manage Folders in Grafana
.. seealso::
List of :ref:`collections <list_of_collections>` with docs hosted here.
.. toctree::
:maxdepth: 1
:hidden:
alert_contact_point_module
alert_notification_policy_module
cloud_api_key_module
cloud_plugin_module
cloud_stack_module
dashboard_module
datasource_module
folder_module

View File

@ -0,0 +1,16 @@
.. _list_of_collections_grafana:
Collections in the Grafana Namespace
====================================
These are the collections documented here in the **grafana** namespace.
* :ref:`grafana.grafana <plugins_in_grafana.grafana>`
.. toctree::
:maxdepth: 1
:hidden:
grafana/index

View File

@ -0,0 +1,17 @@
:orphan:
.. _list_of_collections:
Collection Index
================
These are the collections documented here.
* :ref:`grafana.grafana <plugins_in_grafana.grafana>`
.. toctree::
:maxdepth: 1
:hidden:
grafana/index

View File

@ -0,0 +1,20 @@
:orphan:
.. _list_of_module_plugins:
Index of all Modules
====================
grafana.grafana
---------------
* :ref:`grafana.grafana.alert_contact_point <ansible_collections.grafana.grafana.alert_contact_point_module>` -- Manage Alerting Contact points in Grafana
* :ref:`grafana.grafana.alert_notification_policy <ansible_collections.grafana.grafana.alert_notification_policy_module>` -- Sets the notification policy tree in Grafana Alerting
* :ref:`grafana.grafana.cloud_api_key <ansible_collections.grafana.grafana.cloud_api_key_module>` -- Manage Grafana Cloud API keys
* :ref:`grafana.grafana.cloud_plugin <ansible_collections.grafana.grafana.cloud_plugin_module>` -- Manage Grafana Cloud Plugins
* :ref:`grafana.grafana.cloud_stack <ansible_collections.grafana.grafana.cloud_stack_module>` -- Manage Grafana Cloud stack
* :ref:`grafana.grafana.dashboard <ansible_collections.grafana.grafana.dashboard_module>` -- Manage Dashboards in Grafana
* :ref:`grafana.grafana.datasource <ansible_collections.grafana.grafana.datasource_module>` -- Manage Data sources in Grafana
* :ref:`grafana.grafana.folder <ansible_collections.grafana.grafana.folder_module>` -- Manage Folders in Grafana

25
docs/rst/index.rst Normal file
View File

@ -0,0 +1,25 @@
# Copyright (c) Ansible Project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
.. _docsite_root_index:
Welcome to my Ansible collection documentation
==============================================
This docsite contains documentation of grafana.grafana.
.. toctree::
:maxdepth: 2
:caption: Collections:
collections/index
.. toctree::
:maxdepth: 1
:caption: Plugin indexes:
:glob:
collections/index_*