bitbucket_pipeline_variable – Manages Bitbucket pipeline variables
bitbucket_pipeline_variable – Manages Bitbucket pipeline variables
New in version 2.8.
Synopsis
- Manages Bitbucket pipeline variables.
Parameters
Parameter | Choices/Defaults | Comments |
---|---|---|
client_id string |
The OAuth consumer key. If not set the environment variable | |
client_secret string |
The OAuth consumer secret. If not set the environment variable | |
name string / required |
The pipeline variable name. | |
repository string / required |
The repository name. | |
secured boolean |
|
Whether to encrypt the variable value. |
state string / required |
|
Indicates desired state of the variable. |
username string / required |
The repository owner. | |
value string |
The pipeline variable value. |
Notes
Note
- Bitbucket OAuth consumer key and secret can be obtained from Bitbucket profile -> Settings -> Access Management -> OAuth.
- Check mode is supported.
- For secured values return parameter
changed
is alwaysTrue
.
Examples
- name: Create or update pipeline variables from the list
bitbucket_pipeline_variable:
repository: 'bitbucket-repo'
username: bitbucket_username
name: '{{ item.name }}'
value: '{{ item.value }}'
secured: '{{ item.secured }}'
state: present
with_items:
- { name: AWS_ACCESS_KEY, value: ABCD1234 }
- { name: AWS_SECRET, value: qwe789poi123vbn0, secured: True }
- name: Remove pipeline variable
bitbucket_pipeline_variable:
repository: bitbucket-repo
username: bitbucket_username
name: AWS_ACCESS_KEY
state: absent
Status
- This module is not guaranteed to have a backwards compatible interface. [preview]
- This module is maintained by the Ansible Community. [community]
Authors
- Evgeniy Krysanov (@catcombo)
© 2012–2018 Michael DeHaan
© 2018–2019 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/2.8/modules/bitbucket_pipeline_variable_module.html