mirror of
https://github.com/ansible-collections/kubernetes.core.git
synced 2026-05-07 05:22:39 +00:00
Migrate k8s (#311)
* Use refactored module_utils Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Fix runner Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Fix runner Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Update runner.py * black runner Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Fix units Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Fix ResourceTimeout Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Attempt to fix 'Create custom resource' Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Update svc.find_resource(..., fail=True) Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Attempt to fix integration tests Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Fix apiVersion for Job Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Fix crd Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Add exception = None Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Fix apiVersion for definition Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Fix assert Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Fix returned results Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Update runner to return results accordingly Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Fix assert Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Add validate-missing Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Update client.py * Fix failures * Fix black formatting Co-authored-by: Mike Graves <mgraves@redhat.com>
This commit is contained in:
committed by
Mike Graves
parent
58a0fb1605
commit
3bf147580f
@@ -5,7 +5,7 @@
|
||||
# This is a job definition that runs for 10 minutes and won't gracefully
|
||||
# shutdown. It allows us to test foreground vs background deletion.
|
||||
job_definition:
|
||||
apiVersion: v1
|
||||
apiVersion: batch/v1
|
||||
kind: Job
|
||||
metadata:
|
||||
name: "{{ gc_name }}"
|
||||
|
||||
@@ -97,6 +97,7 @@
|
||||
- name: patch service using json merge patch
|
||||
kubernetes.core.k8s:
|
||||
kind: Deployment
|
||||
api_version: apps/v1
|
||||
namespace: "{{ k8s_patch_namespace }}"
|
||||
name: "{{ k8s_merge }}"
|
||||
merge_type:
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
assert:
|
||||
that:
|
||||
- patch_resource.changed
|
||||
- patch_resource.result.results | selectattr('warning', 'defined') | list | length == 1
|
||||
- patch_resource.result.results | selectattr('warnings', 'defined') | list | length == 1
|
||||
|
||||
- name: Ensure namespace {{ patch_only_namespace[0] }} was patched correctly
|
||||
kubernetes.core.k8s_info:
|
||||
|
||||
@@ -150,7 +150,7 @@
|
||||
- name: Reapply the earlier deployment
|
||||
k8s:
|
||||
definition:
|
||||
api_version: apps/v1
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: scale-deploy
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
- assert:
|
||||
that:
|
||||
- k8s_no_validate is failed
|
||||
- "k8s_no_validate.msg == 'kubernetes-validate python library is required to validate resources'"
|
||||
- "'Failed to import the required Python library (kubernetes-validate)' in k8s_no_validate.msg"
|
||||
|
||||
- file:
|
||||
path: "{{ virtualenv }}"
|
||||
|
||||
Reference in New Issue
Block a user