Ansible module to create and delete Couchbase buckets #35

Open
wants to merge 1 commit into
from

Projects

None yet

7 participants

@renaulth
renaulth commented Oct 1, 2014

Ansible module to create and delete Couchbase buckets, using the Couchbase REST API.

@mpdehaan mpdehaan added the new_module label Dec 8, 2014
@gregdek
Contributor
gregdek commented Jun 16, 2015

Thanks for submitting your module to Ansible Extras. Our policy is that each new module needs to be reviewed and approved by at least two official module reviewers, the list of whom can be found here: https://github.com/ansible/ansible-modules-extras/blob/devel/REVIEWERS.md

If you know someone on that list, please poke them and encourage them to review your module. :)

To ensure that your module has the best chance of being approved, please double-check that you adhere to the Ansible module guidelines: http://docs.ansible.com/developing_modules.html#module-checklist

@robynbergeron robynbergeron removed the P4 label Sep 25, 2015
@robynbergeron
Contributor

Adding new process. We will be evaluating all new module PRs according to this process, effective immediately.

Thanks for submitting this new module to Ansible Extras! This module is now in community review, a process that is open to all Ansible users. In order for this module to be approved, it must gain the following votes:

“works_for_me”: If you have tested the module thoroughly, including testing of all of the module’s options, and if the module works for you, please add “works_for_me” in the comments.

“passes_guidelines”: If you have gone through the module guidelines and the module meets all of the requirements, please add “passes_guidelines” in the comments. Guidelines are available here: http://docs.ansible.com/developing_modules.html#module-checklist

“needs_revision”: If the module fails to work for you, or if it doesn’t meet guidelines, please add “needs_revision” in the comments with details about what needs to be fixed.

When a module has both “works_for_me” and “passes_guidelines” tags, we will promote the module for inclusion in Ansible Extras. At this point, you will be expected to maintain the module by fixing bugs and evaluating pull requests in a timely manner.

Thanks again for submitting your Ansible module!

@gregdek gregdek commented on the diff Apr 6, 2016
database/couchbase_bucket.py
+# along with Ansible. If not, see <http://www.gnu.org/licenses/>.
+
+DOCUMENTATION = '''
+---
+module: couchbase_bucket
+short_description: Idempotently creates or deletes Couchbase buckets.
+description:
+ - Creates or removes buckets on the Couchbase server using the Couchbase
+ REST API.
+ 'state' = 'present' and 'force' = 'no', the bucket will be created
+ if it does not exist.
+ 'state' = 'present' and 'force' = 'yes', the bucket will be deleted
+ and recreated if it does exist.
+ 'state' = 'absent' and 'force' = 'no', the bucket will be deleted.
+ 'state' = 'absent' and 'force' = 'yes', the bucket will be deleted.
+version _added: "1.7"
@gregdek
gregdek Apr 6, 2016 Contributor

This is clearly no longer right, but we can always change it if this gets closer

@gundalow
Contributor
gundalow commented Apr 6, 2016

I've poked some people at CouchBase to have a look at this

@gregdek gregdek commented on the diff Apr 6, 2016
database/couchbase_bucket.py
+
+DOCUMENTATION = '''
+---
+module: couchbase_bucket
+short_description: Idempotently creates or deletes Couchbase buckets.
+description:
+ - Creates or removes buckets on the Couchbase server using the Couchbase
+ REST API.
+ 'state' = 'present' and 'force' = 'no', the bucket will be created
+ if it does not exist.
+ 'state' = 'present' and 'force' = 'yes', the bucket will be deleted
+ and recreated if it does exist.
+ 'state' = 'absent' and 'force' = 'no', the bucket will be deleted.
+ 'state' = 'absent' and 'force' = 'yes', the bucket will be deleted.
+version _added: "1.7"
+author: Renault Hess
@gregdek
gregdek Apr 6, 2016 Contributor

Please add your Github ID to this

@aimonb aimonb added a commit to DimensionDataResearch/ansible-modules-extras that referenced this pull request Aug 12, 2016
@relaxdiego @aimonb relaxdiego + aimonb Multiple fixes (Details in the description) (#35)
* Allow setting of load balancer listener IP

This change depends on apache/libcloud#818

* Use RawConfigParser instead of SafeConfigParser

This change keeps get_credentials() from returning false when
DIDATA_PASSWORD is a strong password that contains the '%' symbol.
Before this change, getting an entry with that symbol would cause
a ConfigParser.InterpolationSyntaxError which would cause the function
to return false. The Ansible user would then get a confusion "User
credentials not found" error. Since we don't expect the user to employ
any string interpolation in this file, we might as well do away with it.

* Print out a more helpful message when invalid credentials are provided.

Before this change, Ansible would only print out '' as an error message
because libcloud's InvalidCredentialsError type did not have a message
attribute. This works around that problem by explicitly writing out a
more helpful message when the above exception is caught.
810164b
@aimonb aimonb added a commit to DimensionDataResearch/ansible-modules-extras that referenced this pull request Sep 8, 2016
@relaxdiego @aimonb relaxdiego + aimonb Multiple fixes (Details in the description) (#35)
* Allow setting of load balancer listener IP

This change depends on apache/libcloud#818

* Use RawConfigParser instead of SafeConfigParser

This change keeps get_credentials() from returning false when
DIDATA_PASSWORD is a strong password that contains the '%' symbol.
Before this change, getting an entry with that symbol would cause
a ConfigParser.InterpolationSyntaxError which would cause the function
to return false. The Ansible user would then get a confusion "User
credentials not found" error. Since we don't expect the user to employ
any string interpolation in this file, we might as well do away with it.

* Print out a more helpful message when invalid credentials are provided.

Before this change, Ansible would only print out '' as an error message
because libcloud's InvalidCredentialsError type did not have a message
attribute. This works around that problem by explicitly writing out a
more helpful message when the above exception is caught.
dff2731
@relaxdiego relaxdiego added a commit to DimensionDataResearch/ansible-modules-extras that referenced this pull request Sep 15, 2016
@relaxdiego @relaxdiego relaxdiego + relaxdiego Multiple fixes (Details in the description) (#35)
* Allow setting of load balancer listener IP

This change depends on apache/libcloud#818

* Use RawConfigParser instead of SafeConfigParser

This change keeps get_credentials() from returning false when
DIDATA_PASSWORD is a strong password that contains the '%' symbol.
Before this change, getting an entry with that symbol would cause
a ConfigParser.InterpolationSyntaxError which would cause the function
to return false. The Ansible user would then get a confusion "User
credentials not found" error. Since we don't expect the user to employ
any string interpolation in this file, we might as well do away with it.

* Print out a more helpful message when invalid credentials are provided.

Before this change, Ansible would only print out '' as an error message
because libcloud's InvalidCredentialsError type did not have a message
attribute. This works around that problem by explicitly writing out a
more helpful message when the above exception is caught.
844c281
@relaxdiego relaxdiego added a commit to DimensionDataResearch/ansible-modules-extras that referenced this pull request Sep 15, 2016
@relaxdiego @relaxdiego relaxdiego + relaxdiego Multiple fixes (Details in the description) (#35)
* Allow setting of load balancer listener IP

This change depends on apache/libcloud#818

* Use RawConfigParser instead of SafeConfigParser

This change keeps get_credentials() from returning false when
DIDATA_PASSWORD is a strong password that contains the '%' symbol.
Before this change, getting an entry with that symbol would cause
a ConfigParser.InterpolationSyntaxError which would cause the function
to return false. The Ansible user would then get a confusion "User
credentials not found" error. Since we don't expect the user to employ
any string interpolation in this file, we might as well do away with it.

* Print out a more helpful message when invalid credentials are provided.

Before this change, Ansible would only print out '' as an error message
because libcloud's InvalidCredentialsError type did not have a message
attribute. This works around that problem by explicitly writing out a
more helpful message when the above exception is caught.
e930358
@ansibot
ansibot commented Dec 6, 2016

This repository has been locked. All new issues and pullrequests should be filed in https://github.com/ansible/ansible

Please read through the repomerge page in the dev guide. The guide contains links to tools which automatically move your issue or pullrequest to the ansible/ansible repo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment