mirror of
https://github.com/openshift/community.okd.git
synced 2026-07-30 11:24:34 +00:00
* Upgrade Ansible and OKD versions for CI * Use ubi9 and fix sanity * Use correct pip install * Try using quotes * Ensure python3.9 * Upgrade ansible and molecule versions * Remove DeploymentConfig DeploymentConfigs are deprecated and seem to now be causing idempotence problems. Replacing them with Deployments fixes it. * Attempt to fix ldap integration tests Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Move sanity and unit tests to GH actions Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Firt round of sanity fixes Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Add kubernetes.core collection as sanity requirement Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Add ignore-2.16.txt Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Attempt to fix units Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Add ignore-2.17 Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Attempt to fix unit tests Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Add pytest-ansible to test-requirements.txt Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Add changelog fragment Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Add workflow for ansible-lint Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Apply black Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Fix linters Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Add # fmt: skip Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Yet another round of linting Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Yet another round of linting Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Remove setup.cfg Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Revert #fmt Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Use ansible-core 2.14 Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Cleanup ansible-lint ignores Signed-off-by: Alina Buzachis <abuzachis@redhat.com> * Try using service instead of pod IP * Fix typo * Actually use the correct port * See if NetworkPolicy is preventing connection * using Pod internal IP * fix adm prune auth roles syntax * adding some retry steps * fix: openshift_builds target * add flag --force-with-deps when building downstream collection * Remove yamllint from tox linters, bump minimum python supported version to 3.9, Remove support for ansible-core < 2.14 --------- Signed-off-by: Alina Buzachis <abuzachis@redhat.com> Co-authored-by: Mike Graves <mgraves@redhat.com> Co-authored-by: Alina Buzachis <abuzachis@redhat.com>
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
---
|
||||
- name: Get cluster information
|
||||
- name: Get cluster information
|
||||
kubernetes.core.k8s_cluster_info:
|
||||
register: info
|
||||
|
||||
@@ -16,30 +16,29 @@
|
||||
app: ldap
|
||||
spec:
|
||||
containers:
|
||||
- name: ldap
|
||||
image: bitnami/openldap
|
||||
env:
|
||||
- name: LDAP_ADMIN_USERNAME
|
||||
value: "{{ ldap_admin_user }}"
|
||||
- name: LDAP_ADMIN_PASSWORD
|
||||
value: "{{ ldap_admin_password }}"
|
||||
- name: LDAP_USERS
|
||||
value: "ansible"
|
||||
- name: LDAP_PASSWORDS
|
||||
value: "ansible123"
|
||||
- name: LDAP_ROOT
|
||||
value: "{{ ldap_root }}"
|
||||
ports:
|
||||
- containerPort: 1389
|
||||
- name: ldap
|
||||
image: bitnami/openldap
|
||||
env:
|
||||
- name: LDAP_ADMIN_USERNAME
|
||||
value: "{{ ldap_admin_user }}"
|
||||
- name: LDAP_ADMIN_PASSWORD
|
||||
value: "{{ ldap_admin_password }}"
|
||||
- name: LDAP_USERS
|
||||
value: "ansible"
|
||||
- name: LDAP_PASSWORDS
|
||||
value: "ansible123"
|
||||
- name: LDAP_ROOT
|
||||
value: "{{ ldap_root }}"
|
||||
ports:
|
||||
- containerPort: 1389
|
||||
name: ldap-server
|
||||
register: pod_info
|
||||
|
||||
- name: Set Pod Internal IP
|
||||
set_fact:
|
||||
podIp: "{{ pod_info.result.status.podIP }}"
|
||||
|
||||
- name: Set LDAP Common facts
|
||||
set_fact:
|
||||
ldap_server_uri: "ldap://{{ podIp }}:1389"
|
||||
# we can use the Pod IP directly because the integration are running inside a Pod in the
|
||||
# same openshift cluster
|
||||
ldap_server_uri: "ldap://{{ pod_info.result.status.podIP }}:1389"
|
||||
ldap_bind_dn: "cn={{ ldap_admin_user }},{{ ldap_root }}"
|
||||
ldap_bind_pw: "{{ ldap_admin_password }}"
|
||||
|
||||
@@ -53,8 +52,10 @@
|
||||
bind_pw: "{{ ldap_bind_pw }}"
|
||||
dn: "ou=users,{{ ldap_root }}"
|
||||
server_uri: "{{ ldap_server_uri }}"
|
||||
# ignore_errors: true
|
||||
# register: ping_ldap
|
||||
register: test_ldap
|
||||
retries: 10
|
||||
delay: 5
|
||||
until: test_ldap is not failed
|
||||
|
||||
- include_tasks: "tasks/python-ldap-not-installed.yml"
|
||||
- include_tasks: "tasks/rfc2307.yml"
|
||||
|
||||
Reference in New Issue
Block a user