mirror of
https://github.com/openshift/community.okd.git
synced 2026-11-22 07:00:26 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
18afe96096 | ||
|
|
a37175c6f9 | ||
|
|
b4950f525c |
@@ -0,0 +1,15 @@
|
|||||||
|
---
|
||||||
|
|
||||||
|
profile: production
|
||||||
|
|
||||||
|
exclude_paths:
|
||||||
|
- tests/unit
|
||||||
|
- tests/sanity
|
||||||
|
- molecule
|
||||||
|
- changelogs
|
||||||
|
- docs
|
||||||
|
- .ansible
|
||||||
|
- .github
|
||||||
|
|
||||||
|
warn_list:
|
||||||
|
- no-log-password
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
profile: production
|
|
||||||
exclude_paths:
|
|
||||||
- molecule
|
|
||||||
- tests/sanity
|
|
||||||
+8
-8
@@ -5,26 +5,26 @@ ENV OPERATOR=/usr/local/bin/ansible-operator \
|
|||||||
USER_NAME=ansible-operator\
|
USER_NAME=ansible-operator\
|
||||||
HOME=/opt/ansible \
|
HOME=/opt/ansible \
|
||||||
ANSIBLE_LOCAL_TMP=/opt/ansible/tmp \
|
ANSIBLE_LOCAL_TMP=/opt/ansible/tmp \
|
||||||
DOWNSTREAM_BUILD_PYTHON=python3.9
|
DOWNSTREAM_BUILD_PYTHON=python3.12
|
||||||
|
|
||||||
RUN yum install -y \
|
RUN yum install -y \
|
||||||
glibc-langpack-en \
|
glibc-langpack-en \
|
||||||
git \
|
git \
|
||||||
make \
|
make \
|
||||||
python3 \
|
python3.12 \
|
||||||
python3-devel \
|
python3.12-devel \
|
||||||
python3-pip \
|
python3.12-pip \
|
||||||
python3-setuptools \
|
python3.12-setuptools \
|
||||||
gcc \
|
gcc \
|
||||||
openldap-devel \
|
openldap-devel \
|
||||||
&& python3.9 -m pip install --no-cache-dir --upgrade setuptools pip \
|
&& python3.12 -m pip install --no-cache-dir --upgrade setuptools pip \
|
||||||
&& python3.9 -m pip install --no-cache-dir \
|
&& python3.12 -m pip install --no-cache-dir \
|
||||||
kubernetes \
|
kubernetes \
|
||||||
"ansible-core" \
|
"ansible-core" \
|
||||||
"molecule" \
|
"molecule" \
|
||||||
&& yum clean all \
|
&& yum clean all \
|
||||||
&& rm -rf $HOME/.cache \
|
&& rm -rf $HOME/.cache \
|
||||||
&& curl -L https://github.com/openshift/okd/releases/download/4.12.0-0.okd-2023-04-16-041331/openshift-client-linux-4.12.0-0.okd-2023-04-16-041331.tar.gz | tar -xz -C /usr/local/bin
|
&& curl -L https://github.com/okd-project/okd/releases/download/4.20.0-okd-scos.17/openshift-client-linux-amd64-rhel9-4.20.0-okd-scos.17.tar.gz | tar -xz -C /usr/local/bin
|
||||||
# TODO: Is there a better way to install this client in ubi8?
|
# TODO: Is there a better way to install this client in ubi8?
|
||||||
|
|
||||||
COPY . /opt/ansible
|
COPY . /opt/ansible
|
||||||
|
|||||||
+1
-1
@@ -64,6 +64,7 @@ f_prep()
|
|||||||
# Files to copy downstream (relative repo root dir path)
|
# Files to copy downstream (relative repo root dir path)
|
||||||
_file_manifest=(
|
_file_manifest=(
|
||||||
.gitignore
|
.gitignore
|
||||||
|
.ansible-lint
|
||||||
CHANGELOG.rst
|
CHANGELOG.rst
|
||||||
galaxy.yml
|
galaxy.yml
|
||||||
LICENSE
|
LICENSE
|
||||||
@@ -77,7 +78,6 @@ f_prep()
|
|||||||
|
|
||||||
# Directories to recursively copy downstream (relative repo root dir path)
|
# Directories to recursively copy downstream (relative repo root dir path)
|
||||||
_dir_manifest=(
|
_dir_manifest=(
|
||||||
.config
|
|
||||||
changelogs
|
changelogs
|
||||||
ci
|
ci
|
||||||
meta
|
meta
|
||||||
|
|||||||
@@ -23,8 +23,8 @@ provisioner:
|
|||||||
host_vars:
|
host_vars:
|
||||||
localhost:
|
localhost:
|
||||||
virtualenv: ${MOLECULE_EPHEMERAL_DIRECTORY}/virtualenv
|
virtualenv: ${MOLECULE_EPHEMERAL_DIRECTORY}/virtualenv
|
||||||
virtualenv_command: '{{ ansible_playbook_python }} -m virtualenv'
|
virtualenv_command: '{{ ansible_playbook_python }} -m venv'
|
||||||
virtualenv_interpreter: '{{ virtualenv }}/bin/python'
|
virtualenv_interpreter: '{{ virtualenv }}/bin/python3'
|
||||||
playbook_namespace: molecule-tests
|
playbook_namespace: molecule-tests
|
||||||
env:
|
env:
|
||||||
ANSIBLE_FORCE_COLOR: 'true'
|
ANSIBLE_FORCE_COLOR: 'true'
|
||||||
|
|||||||
@@ -13,6 +13,7 @@
|
|||||||
- kubernetes>=12.0.0
|
- kubernetes>=12.0.0
|
||||||
- coverage
|
- coverage
|
||||||
- python-ldap
|
- python-ldap
|
||||||
|
- packaging
|
||||||
virtualenv: "{{ virtualenv }}"
|
virtualenv: "{{ virtualenv }}"
|
||||||
virtualenv_command: "{{ virtualenv_command }}"
|
virtualenv_command: "{{ virtualenv_command }}"
|
||||||
virtualenv_site_packages: no
|
virtualenv_site_packages: no
|
||||||
|
|||||||
@@ -47,8 +47,8 @@
|
|||||||
assert:
|
assert:
|
||||||
that:
|
that:
|
||||||
- result is changed
|
- result is changed
|
||||||
- admins_group
|
- admins_group | length > 0
|
||||||
- devs_group
|
- devs_group | length > 0
|
||||||
- '"jane.smith@ansible.org" in admins_group.users'
|
- '"jane.smith@ansible.org" in admins_group.users'
|
||||||
- '"jim.adams@ansible.org" in admins_group.users'
|
- '"jim.adams@ansible.org" in admins_group.users'
|
||||||
- '"jordanbulls@ansible.org" in devs_group.users'
|
- '"jordanbulls@ansible.org" in devs_group.users'
|
||||||
|
|||||||
@@ -47,8 +47,8 @@
|
|||||||
assert:
|
assert:
|
||||||
that:
|
that:
|
||||||
- result is changed
|
- result is changed
|
||||||
- banking_group
|
- banking_group | length > 0
|
||||||
- insurance_group
|
- insurance_group | length > 0
|
||||||
- '"james-allan@ansible.org" in banking_group.users'
|
- '"james-allan@ansible.org" in banking_group.users'
|
||||||
- '"gordon-kane@ansible.org" in banking_group.users'
|
- '"gordon-kane@ansible.org" in banking_group.users'
|
||||||
- '"alice-courtney@ansible.org" in insurance_group.users'
|
- '"alice-courtney@ansible.org" in insurance_group.users'
|
||||||
|
|||||||
@@ -17,7 +17,8 @@
|
|||||||
spec:
|
spec:
|
||||||
containers:
|
containers:
|
||||||
- name: ldap
|
- name: ldap
|
||||||
image: bitnami/openldap
|
# bitnami is no longer supporting this image. we should probably find a replacement
|
||||||
|
image: docker.io/bitnamilegacy/openldap:latest
|
||||||
env:
|
env:
|
||||||
- name: LDAP_ADMIN_USERNAME
|
- name: LDAP_ADMIN_USERNAME
|
||||||
value: "{{ ldap_admin_user }}"
|
value: "{{ ldap_admin_user }}"
|
||||||
|
|||||||
@@ -13,10 +13,8 @@
|
|||||||
|
|
||||||
- pip:
|
- pip:
|
||||||
name:
|
name:
|
||||||
- kubernetes
|
- python-ldap
|
||||||
virtualenv: "{{ venv }}"
|
state: absent
|
||||||
virtualenv_command: "{{ virtualenv_command }}"
|
|
||||||
virtualenv_site_packages: false
|
|
||||||
|
|
||||||
- name: Load test configurations
|
- name: Load test configurations
|
||||||
set_fact:
|
set_fact:
|
||||||
@@ -27,8 +25,6 @@
|
|||||||
config: "{{ configs.simple }}"
|
config: "{{ configs.simple }}"
|
||||||
register: result
|
register: result
|
||||||
ignore_errors: true
|
ignore_errors: true
|
||||||
vars:
|
|
||||||
ansible_python_interpreter: "{{ venv }}/bin/python"
|
|
||||||
|
|
||||||
- name: Check that module failed gracefully
|
- name: Check that module failed gracefully
|
||||||
assert:
|
assert:
|
||||||
@@ -36,6 +32,9 @@
|
|||||||
- '"Failed to import the required Python library (python-ldap)" in result.msg'
|
- '"Failed to import the required Python library (python-ldap)" in result.msg'
|
||||||
|
|
||||||
always:
|
always:
|
||||||
|
- pip:
|
||||||
|
name:
|
||||||
|
- python-ldap
|
||||||
- name: Remove temp directory
|
- name: Remove temp directory
|
||||||
file:
|
file:
|
||||||
path: "{{ test_dir }}"
|
path: "{{ test_dir }}"
|
||||||
|
|||||||
@@ -68,8 +68,8 @@
|
|||||||
assert:
|
assert:
|
||||||
that:
|
that:
|
||||||
- result is changed
|
- result is changed
|
||||||
- admins_group
|
- admins_group | length > 0
|
||||||
- devs_group
|
- devs_group | length > 0
|
||||||
- '"jane.smith@ansible.org" in admins_group.users'
|
- '"jane.smith@ansible.org" in admins_group.users'
|
||||||
- '"jim.adams@ansible.org" in devs_group.users'
|
- '"jim.adams@ansible.org" in devs_group.users'
|
||||||
- '"jordanbulls@ansible.org" in devs_group.users'
|
- '"jordanbulls@ansible.org" in devs_group.users'
|
||||||
@@ -89,8 +89,8 @@
|
|||||||
assert:
|
assert:
|
||||||
that:
|
that:
|
||||||
- result is changed
|
- result is changed
|
||||||
- admins_group
|
- admins_group | length > 0
|
||||||
- devs_group
|
- devs_group | length > 0
|
||||||
- '"jane.smith@ansible.org" in admins_group.users'
|
- '"jane.smith@ansible.org" in admins_group.users'
|
||||||
- '"jim.adams@ansible.org" in devs_group.users'
|
- '"jim.adams@ansible.org" in devs_group.users'
|
||||||
- '"jordanbulls@ansible.org" in devs_group.users'
|
- '"jordanbulls@ansible.org" in devs_group.users'
|
||||||
@@ -110,8 +110,8 @@
|
|||||||
assert:
|
assert:
|
||||||
that:
|
that:
|
||||||
- result is changed
|
- result is changed
|
||||||
- admins_group
|
- admins_group | length > 0
|
||||||
- devs_group
|
- devs_group | length > 0
|
||||||
- '"cn=Jane,ou=people,ou=rfc2307,"+ldap_root in admins_group.users'
|
- '"cn=Jane,ou=people,ou=rfc2307,"+ldap_root in admins_group.users'
|
||||||
- '"cn=Jim,ou=people,ou=rfc2307,"+ldap_root in devs_group.users'
|
- '"cn=Jim,ou=people,ou=rfc2307,"+ldap_root in devs_group.users'
|
||||||
- '"cn=Jordan,ou=people,ou=rfc2307,"+ldap_root in devs_group.users'
|
- '"cn=Jordan,ou=people,ou=rfc2307,"+ldap_root in devs_group.users'
|
||||||
@@ -131,8 +131,8 @@
|
|||||||
assert:
|
assert:
|
||||||
that:
|
that:
|
||||||
- result is changed
|
- result is changed
|
||||||
- admins_group
|
- admins_group | length > 0
|
||||||
- devs_group
|
- devs_group | length > 0
|
||||||
- '"jane.smith@ansible.org" in admins_group.users'
|
- '"jane.smith@ansible.org" in admins_group.users'
|
||||||
- '"jim.adams@ansible.org" in devs_group.users'
|
- '"jim.adams@ansible.org" in devs_group.users'
|
||||||
- '"jordanbulls@ansible.org" in devs_group.users'
|
- '"jordanbulls@ansible.org" in devs_group.users'
|
||||||
|
|||||||
@@ -213,5 +213,6 @@
|
|||||||
ignore_errors: true
|
ignore_errors: true
|
||||||
|
|
||||||
when:
|
when:
|
||||||
- registry.public_hostname
|
- registry.public_hostname is not none
|
||||||
|
- registry.public_hostname | length > 0
|
||||||
- registry.check.reached
|
- registry.check.reached
|
||||||
|
|||||||
@@ -44,10 +44,7 @@
|
|||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
- pip:
|
- pip:
|
||||||
name: kubernetes-validate==1.12.0
|
name: kubernetes-validate==1.34.1
|
||||||
virtualenv: "{{ virtualenv }}"
|
|
||||||
virtualenv_command: "{{ virtualenv_command }}"
|
|
||||||
virtualenv_site_packages: no
|
|
||||||
|
|
||||||
- import_tasks: tasks/validate_installed.yml
|
- import_tasks: tasks/validate_installed.yml
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user