Commit Graph

19 Commits

Author SHA1 Message Date
Wissem BEN CHAABANE
4fa1fb966b Add helm dependency update (#208)
Add helm dependency update

SUMMARY

Execute the helm dependency update under the hood when found dependencies block in Chart.yaml file.
Support the execution of:

Standalone dependency update by executing: helm dependency update CHART
Inline dependency update when specifying the helm chart_repo_url by adding --dependency-update to the helm install command.


ISSUE TYPE


Feature Pull Request #191

COMPONENT NAME

helm, helm_template
ADDITIONAL INFORMATION





There is a doc generated for history_max option for the helm module. I think that is not generated in the previous PR #164.


There is others changes affect the docs/ folder when I run the collection_prep_add_docs -p .  command. These changes are added in the last commit  64eab40. I let you decide rather we keep the commit or remove it.


The --dependency-update insertion option is tested used a local helm chart repository create via docker. So here are the tasks that test this feature.  Maybe if we create a GitHub repository for the helm chart, we can add this test code in the CI pipeline.


# Test The update dependency with chart_repo_url
- name: "Test chart without dependencies block and chart_repo_url defined"
  block:
    - name: "Test chart without dependencies block and chart_repo_url defined"
      helm:
        binary_path: "{{ helm_binary }}"
        name: test
        chart_ref: "ingress-nginx"
        chart_repo_url: https://kubernetes.github.io/ingress-nginx
        chart_version: "{{ chart_source_version | default(omit) }}"
        namespace: "{{ helm_namespace }}"
        create_namespace: yes
      register: release

    - assert:
        that:
          - "'--dependency-update' not in release.command"
          - "'upgrade' in release.command"
        success_msg: "Command does not contains '--dependency-update' options"
        fail_msg: "Command contains '--dependency-update' options"

- name: "Test chart with dependencies block and chart_repo_url defined and replace True"
  block:
    - name: "Test chart with dependencies block and chart_repo_url defined and replace True"
      helm:
        binary_path: "{{ helm_binary }}"
        name: test1
        chart_ref: "dep_up"
        chart_repo_url: http://repo:8080/charts
        chart_version: "{{ chart_source_version | default(omit) }}"
        namespace: "{{ helm_namespace }}"
        create_namespace: yes
        replace: true
      register: release
    - debug: var=release
    - assert:
        that:
          - "'--dependency-update' in release.command"
          - "'install' in release.command"
        success_msg: "Command contains '--dependency-update' options with helm install command"
        fail_msg: "Command not contains '--dependency-update' with helm install command"

- name: "Test chart with dependencies block and chart_repo_url defined and replace False fails"
  block:
    - name: "Test chart with dependencies block and chart_repo_url defined and replace False fails"
      helm:
        binary_path: "{{ helm_binary }}"
        name: test2
        chart_ref: "dep_up"
        chart_repo_url: http://repo:8080/charts
        chart_version: "{{ chart_source_version | default(omit) }}"
        namespace: "{{ helm_namespace }}"
        create_namespace: yes
        replace: false
      register: release
      ignore_errors: true

    - assert:
        that:
          - release.failed
          - release.msg == "'--dependency-update' hasn't been supported yet with 'helm upgrade'. Please use 'helm install' instead by adding 'replace' option"
        success_msg: "Command build fail when adding  '--dependency-update' with the helm upgrade command"

Reviewed-by: Mike Graves <mgraves@redhat.com>
Reviewed-by: Wissem BEN CHAABANE <benchaaben.wissem@gmail.com>
Reviewed-by: Bikouo Aubin <None>
2022-04-26 11:54:37 +00:00
Major Hayden
db78d3a505 Docs: Small fix for k8s example (#397)
Docs: Small fix for k8s example

SUMMARY
Update the k8s example to use kubernetes.core.k8s instead of the bare k8s and fix the indentation.
ISSUE TYPE

Docs Pull Request

COMPONENT NAME
kubernetes.core
ADDITIONAL INFORMATION
Just a small documentation fix. 😉

Reviewed-by: Mike Graves <mgraves@redhat.com>
2022-03-08 16:06:10 +00:00
Max Gautier
9a0b3fe30c Documentation update for kubernetes.core.helm (#317)
Documentation update for kubernetes.core.helm

Clarify usage of the module for doing helm repo update only.
I used collection_prep_add_docs as explained in CONTRIBUTING.md, not sure if
that's correct ?
Fixes #316
@Akasurde

Reviewed-by: Abhijeet Kasurde <None>
Reviewed-by: Mike Graves <mgraves@redhat.com>
Reviewed-by: None <None>
2022-01-13 14:47:17 +00:00
Jorn Eilander
c3ecb64b72 Add delete_emptydir_data to drain delete_options (#322)
Add delete_emptydir_data to drain delete_options

SUMMARY
Adds delete_emptydir_data option to k8s_drain.delete_options to evict pods with an emptyDir volume attached.
ISSUE TYPE

Feature Pull Request

COMPONENT NAME
k8s_drain
ADDITIONAL INFORMATION
Be gentle, this is my first pull request 😨 
Basically adds the kubectl drain <node> --delete-emptydir-data feature, including tests.

Reviewed-by: Abhijeet Kasurde <None>
Reviewed-by: Jorn Eilander <None>
Reviewed-by: None <None>
Reviewed-by: None <None>
2022-01-13 13:40:06 +00:00
Mike Graves
a27c701afe Release version 2.2.0 (#234)
Release version 2.2.0

SUMMARY


ISSUE TYPE


Bugfix Pull Request
Docs Pull Request
Feature Pull Request
New Module Pull Request

COMPONENT NAME

ADDITIONAL INFORMATION

Reviewed-by: Jill R <None>
Reviewed-by: None <None>
Reviewed-by: Alina Buzachis <None>
Reviewed-by: None <None>
2021-09-16 12:28:33 +00:00
itaru2622
07ac24e42e fix k8s_exec, returning rc attribute to follow ansible's common return values. (#230)
fix k8s_exec, returning rc attribute to follow ansible's common return values.

SUMMARY

fix #229.

ISSUE TYPE


Bugfix Pull Request

COMPONENT NAME

k8s_exec
ADDITIONAL INFORMATION

Reviewed-by: None <None>
Reviewed-by: None <None>
2021-09-13 10:21:24 +00:00
Alina Buzachis
8bb455afb9 Minor doc fix turbo mode (#227)
Minor doc fix turbo mode

SUMMARY

Minor doc fix

ISSUE TYPE


Docs Pull Request

COMPONENT NAME

ADDITIONAL INFORMATION

Reviewed-by: Abhijeet Kasurde <None>
Reviewed-by: Mike Graves <mgraves@redhat.com>
Reviewed-by: None <None>
2021-09-08 15:23:03 +00:00
Mike Graves
ddbc161121 Add turbo mode docs (#221)
Add turbo mode docs

SUMMARY

Add turbo mode docs

ISSUE TYPE


Docs Pull Request

COMPONENT NAME

ADDITIONAL INFORMATION

Reviewed-by: Abhijeet Kasurde <None>
Reviewed-by: None <None>
2021-09-02 19:58:43 +00:00
abikouo
b875531c8a k8s_drain new module (#141)
k8s_drain new module

SUMMARY

new module to drain, cordon or uncordon node from k8s cluster.
#141

ISSUE TYPE


New Module Pull Request

COMPONENT NAME

k8s_drain

Reviewed-by: Abhijeet Kasurde <None>
Reviewed-by: None <None>
Reviewed-by: Mike Graves <mgraves@redhat.com>
Reviewed-by: None <None>
2021-08-09 08:00:34 +00:00
abikouo
c330c7ec65 k8s_cp - a new module for copying files to/from a Pod (#127)
* k8s_cp module

* add documentation for k8s_cp module

* add doc for the new module

* pods should be running

* support for binary, archive and zip file

* sanity

* Delete file.txt

* remove unused

* set back

* Update collection.txt

* Update test_copy_errors.yml

* Update plugins/modules/k8s_cp.py

Co-authored-by: Abhijeet Kasurde <akasurde@redhat.com>

* Update k8s_cp.py

* Update k8s_cp.py

* tar binary requirements

* Update common.py

* Update k8s_cp.py

* Update k8s_cp.py

* replace kind with binary file

* Update test_copy_large_file.yml

* Update plugins/action/k8s_info.py

Co-authored-by: Mike Graves <mgraves@redhat.com>

* Update k8s_info.py

* Update k8s_info.py

* Update k8s_cp.py

Co-authored-by: Abhijeet Kasurde <akasurde@redhat.com>
Co-authored-by: Mike Graves <mgraves@redhat.com>
2021-07-26 13:21:34 +02:00
Abhijeet Kasurde
eab3aa29bf Docs: Migrate Scenario Guide to collection (#143)
Migrate scenario guide from ansible/ansible repo to
this collection.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2021-07-09 09:55:47 +05:30
Mike Graves
b7345696cc Release 2.0.1 (#130) 2021-06-14 07:54:07 -04:00
Mike Graves
9e60a3a40d Release version 2.0.0 (#124)
* Release version 2.0.0
2021-06-09 12:50:23 -04:00
Abhijeet Kasurde
eb4b85c17d Add a doc about Ansible Turbo mode (#100) 2021-05-27 09:44:12 +05:30
Elliot Blackburn
e112417d4c Correct helm_info return type docs for app_version (#97) 2021-05-21 13:22:02 +05:30
Abhijeet Kasurde
0eb1559cc7 Update docs (#101) 2021-05-17 13:54:51 +05:30
Abhijeet Kasurde
5f993e6028 Update kubeconfig file location in docs (#65)
Fixes: #53 

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2021-04-19 19:50:14 +05:30
Abhijeet Kasurde
28223dbe36 Fix broken links in docs (#61) 2021-04-16 10:19:47 +05:30
Abhijeet Kasurde
8182a3afd4 Added docs for the collection (#50) 2021-04-12 22:25:10 +05:30