Skip to content
This repository has been archived by the owner on Jun 13, 2024. It is now read-only.

Commit

Permalink
Merge pull request #34 from ansible-collections/33-fix-sanity-checks
Browse files Browse the repository at this point in the history
Fix failing CI tests by updating args in k8s_service
  • Loading branch information
geerlingguy authored Feb 21, 2020
2 parents 3deeabf + b32e260 commit 5491d5b
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
*.retry
.idea
*.log
__pycache__/

# Galaxy artifacts.
*.tar.gz
Expand Down
24 changes: 24 additions & 0 deletions plugins/modules/k8s_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,15 @@
- definition
- inline
type: dict
src:
description:
- "Provide a path to a file containing a valid YAML definition of an object dated. Mutually
exclusive with I(resource_definition). NOTE: I(kind), I(api_version), I(resource_name), and I(namespace)
will be overwritten by corresponding values found in the configuration read in from the I(src) file."
- Reads from the local file system. To read from the Ansible controller's file system, use the file lookup
plugin or template lookup plugin, combined with the from_yaml filter, and pass the result to
I(resource_definition). See Examples below.
type: path
state:
description:
- Determines if an object should be created, patched, or deleted. When set to C(present), an object will be
Expand Down Expand Up @@ -105,6 +114,14 @@
- Label selectors identify objects this Service should apply to.
- U(https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/)
type: dict
apply:
description:
- C(apply) compares the desired resource definition with the previously supplied resource definition,
ignoring properties that are automatically generated
- C(apply) works better with Services than 'force=yes'
- mutually exclusive with C(merge_type)
type: bool
version_added: "2.9"
requirements:
- python >= 2.7
Expand Down Expand Up @@ -176,6 +193,10 @@


SERVICE_ARG_SPEC = {
'apply': {
'type': 'bool',
'default': False,
},
'state': {
'default': 'present',
'choices': ['present', 'absent'],
Expand All @@ -192,6 +213,9 @@
'namespace': {'required': True},
'merge_type': {'type': 'list', 'elements': 'str', 'choices': ['json', 'merge', 'strategic-merge']},
'selector': {'type': 'dict'},
'src': {
'type': 'path',
},
'type': {
'type': 'str',
'choices': [
Expand Down

0 comments on commit 5491d5b

Please sign in to comment.