From 7d41bf1cb74803ae8764c67d8ea2a451cb67c285 Mon Sep 17 00:00:00 2001 From: abakshi Date: Sat, 10 Feb 2024 07:13:29 -0600 Subject: [PATCH] Collection Integration Tests No-Issue --- .../.DS_Store | Bin 0 -> 6148 bytes .../content.yml | 120 ++++++++++++++ .../dispatch.yml | 19 +++ .../ee.yml | 74 +++++++++ .../ee_image.yml | 106 +++++++++++++ .../group_roles.yml | 148 ++++++++++++++++++ .../repo.yml | 63 ++++++++ .../user.yml | 116 ++++++++++++++ .../vars/collection_requirement_file.yml | 6 + .../vars/dispatch_vars.yml | 144 +++++++++++++++++ .../vars/vars.yml | 10 ++ 11 files changed, 806 insertions(+) create mode 100644 dev/galaxy_collection_plays_integration_tests/.DS_Store create mode 100644 dev/galaxy_collection_plays_integration_tests/content.yml create mode 100644 dev/galaxy_collection_plays_integration_tests/dispatch.yml create mode 100644 dev/galaxy_collection_plays_integration_tests/ee.yml create mode 100644 dev/galaxy_collection_plays_integration_tests/ee_image.yml create mode 100644 dev/galaxy_collection_plays_integration_tests/group_roles.yml create mode 100644 dev/galaxy_collection_plays_integration_tests/repo.yml create mode 100644 dev/galaxy_collection_plays_integration_tests/user.yml create mode 100644 dev/galaxy_collection_plays_integration_tests/vars/collection_requirement_file.yml create mode 100644 dev/galaxy_collection_plays_integration_tests/vars/dispatch_vars.yml create mode 100644 dev/galaxy_collection_plays_integration_tests/vars/vars.yml diff --git a/dev/galaxy_collection_plays_integration_tests/.DS_Store b/dev/galaxy_collection_plays_integration_tests/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..d24d856d45330392dd9b538bfbe3277ccc4205fd GIT binary patch literal 6148 zcmeH~JqiLr422WjLa^D=avBfd4F=H@cme-PK~S`wqxKCOXc1A_Ig&|X4TdW4*GF~m!AM6b`{UyZrCrj0Bf=ZQGxMCz-3^d0$)|&0XLHp AzW@LL literal 0 HcmV?d00001 diff --git a/dev/galaxy_collection_plays_integration_tests/content.yml b/dev/galaxy_collection_plays_integration_tests/content.yml new file mode 100644 index 0000000000..b1e2d7e2b5 --- /dev/null +++ b/dev/galaxy_collection_plays_integration_tests/content.yml @@ -0,0 +1,120 @@ +--- +- name: Collection tests - Content + hosts: localhost + connection: local + gather_facts: false + ignore_errors: true + collections: + - galaxy.galaxy + + pre_tasks: + - name: Include variables + ansible.builtin.include_vars: + file: vars/vars.yml + + - name: Include dispatch vars + ansible.builtin.include_vars: + file: vars/dispatch_vars.yml + + tasks: + - name: Create the automate namespace + ah_namespace: + name: automate + company: Automator Inc. + email: automator@redhat.com + description: The namespace for all things automation + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + validate_certs: false + + - name: Rename automate namespace to automator + ah_namespace: + name: automate + new_name: automator + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Delete the automator namespace + ah_namespace: + state: absent + name: automator + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Ensure there is a galaxy namespace + ah_namespace: + name: galaxy + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Ensure there is a infra namespace + ah_namespace: + name: infra + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Creates directory + ansible.builtin.file: + path: "{{ ah_configuration_working_dir }}" + state: directory + + - name: Download Tower tarball + ansible.builtin.get_url: + url: https://galaxy.ansible.com/download/infra-controller_configuration-2.4.0.tar.gz + dest: "{{ ah_configuration_working_dir }}/infra-controller_configuration-2.4.0.tar.gz" + mode: '0440' + + - name: Upload Tower collection to automation hub + ah_collection_upload: + path: "{{ ah_configuration_working_dir }}/infra-controller_configuration-2.4.0.tar.gz" + wait: true + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + validate_certs: false + + - name: Approve the galaxy collection + timeout: 60 + ah_approval: + namespace: infra + name: controller_configuration + version: "2.4.0" + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + validate_certs: false + + - name: Delete the galaxy collection + ah_collection: + state: absent + namespace: infra + name: controller_configuration + version: "2.4.0" + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + validate_certs: false + + - name: Publish Collections + ansible.builtin.include_role: + name: publish + vars: + ah_collections: + - collection_name: cisco.iosxr + git_url: https://github.com/ansible-collections/cisco.iosxr + ah_auto_approve: true + validate_certs: false + diff --git a/dev/galaxy_collection_plays_integration_tests/dispatch.yml b/dev/galaxy_collection_plays_integration_tests/dispatch.yml new file mode 100644 index 0000000000..e75e42262d --- /dev/null +++ b/dev/galaxy_collection_plays_integration_tests/dispatch.yml @@ -0,0 +1,19 @@ +--- +- name: Collection tests - Dispatch role + hosts: localhost + connection: local + gather_facts: false + ignore_errors: true + collections: + - galaxy.galaxy + + pre_tasks: + - name: Include variables + ansible.builtin.include_vars: + file: vars/vars.yml + + - name: Include dispatch vars + ansible.builtin.include_vars: + file: vars/dispatch_vars.yml + roles: + - galaxy.galaxy.dispatch \ No newline at end of file diff --git a/dev/galaxy_collection_plays_integration_tests/ee.yml b/dev/galaxy_collection_plays_integration_tests/ee.yml new file mode 100644 index 0000000000..6f286ad94f --- /dev/null +++ b/dev/galaxy_collection_plays_integration_tests/ee.yml @@ -0,0 +1,74 @@ +--- +- name: Collection tests - EE + hosts: localhost + connection: local + gather_facts: false + ignore_errors: true + collections: + - galaxy.galaxy + + pre_tasks: + - name: Include variables + ansible.builtin.include_vars: + file: vars.yml + + tasks: + - name: Add redhat.io registry + ah_ee_registry: + name: redhat + url: https://registry.redhat.io + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + validate_certs: false + + - name: create a repo + ah_ee_repository: + name: ansible-automation-platform-19/ee-29-rhel8 + description: AAP RHEL execution environment + registry: redhat + upstream_name: redhat + readme: | + # RHEL execution environment + * Contains ansible + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + validate_certs: false + + - name: Index redhat.io registry + ah_ee_registry_index: + name: redhat + wait: true + timeout: 300 + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + + - name: Registry Sync + ah_ee_registry_sync: + name: redhat + wait: true + timeout: 300 + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + + - name: Repo Sync + ah_ee_repository_sync: + name: ansible-automation-platform-19/ee-29-rhel8 + wait: true + timeout: 300 + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + + - name: Delete the redhat.io registry + ah_ee_registry: + name: redhat + state: absent + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + validate_certs: false + diff --git a/dev/galaxy_collection_plays_integration_tests/ee_image.yml b/dev/galaxy_collection_plays_integration_tests/ee_image.yml new file mode 100644 index 0000000000..f4dd0799b0 --- /dev/null +++ b/dev/galaxy_collection_plays_integration_tests/ee_image.yml @@ -0,0 +1,106 @@ +--- +- name: Collection tests - EE Image + hosts: localhost + connection: local + become: false + gather_facts: false + ignore_errors: true + collections: + - galaxy.galaxy + vars: + repository: test-namespace/ee-minimal-rhel8 + tag: latest + fake_image: quay.io/ansible/http-test-container:2.0.0 + pre_tasks: + - name: Include variables + ansible.builtin.include_vars: + file: vars/vars.yml + + tasks: + - name: Ensure a small container image is available + ansible.builtin.command: + cmd: "podman pull {{ fake_image }}" + changed_when: true + + - name: Ensure the image has the correct tag + ansible.builtin.command: + cmd: "podman tag {{ fake_image }} {{ hub_host }}/{{ repository }}:{{ tag }}" + changed_when: true + + - name: Ensure the image is pushed in private automation hub + ansible.builtin.command: + cmd: "podman push --tls-verify=false --remove-signatures + --creds={{ ah_username }}:{{ ah_password }} + {{ hub_host }}/{{ repository }}:{{ tag }}" + changed_when: true + + # Preparing a README file + - name: Ensure a temporary file exists + ansible.builtin.tempfile: + register: tempfile + + - name: Ensure some contents are stored in the temporary file + ansible.builtin.copy: + dest: "{{ tempfile['path'] }}" + mode: 0600 + content: | + # Mi entorno de ejecución + + * bullet 1 + * bullet 2 + + - name: Create repository + ah_ee_repository: + name: ansible-automation-platform-19/ee-29-rhel8 + registry: redhat + upstream_name: redhat + state: present + description: Supported execution environment + include_tags: latest + readme: | + # My execution environment + + * bullet 1 + * bullet 2 + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + + - name: Tag image + ah_ee_image: + name: ansible-automation-platform-19/ee-29-rhel8:latest + state: present + append: false + tags: + - v2 + - "2.0" + - prod1 + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + + - name: Append Tags to image + ah_ee_image: + name: ansible-automation-platform-19/ee-29-rhel8:2.0.0-15 + state: present + append: true + tags: + - prod2 + - prod2.0 + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + + - name: Remove image + ah_ee_image: + name: ansible-automation-platform-19/ee-29-rhel8:2.0.0-15 + state: absent + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + + - name: Ensure the images are removed + ansible.builtin.command: + cmd: "podman rmi {{ fake_image }} {{ hub_host }}/{{ repository }}:{{ tag }}" + changed_when: true +... \ No newline at end of file diff --git a/dev/galaxy_collection_plays_integration_tests/group_roles.yml b/dev/galaxy_collection_plays_integration_tests/group_roles.yml new file mode 100644 index 0000000000..c47a908461 --- /dev/null +++ b/dev/galaxy_collection_plays_integration_tests/group_roles.yml @@ -0,0 +1,148 @@ +--- +- name: Collection tests - Group roles + hosts: localhost + connection: local + gather_facts: false + ignore_errors: true + collections: + - galaxy.galaxy + + pre_tasks: + - name: Include variables + ansible.builtin.include_vars: + file: vars.yml + + tasks: + - name: Create a group + ah_group: + name: revoke_access_test + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Add user to the group + ah_user: + username: "access_test_user" + password: "access_test_user" + first_name: "access_test_user" + last_name: "access_test_user" + groups: + - revoke_access_test + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: create a collection remote as that user, expected to fail + collection_remote: + name: community-test-group-roles + url: https://beta-galaxy.ansible.com/ + requirements: + - name: infra.ee_utilities + - name: infra.controller_configuration + ah_host: "{{ ah_host }}" + ah_username: "access_test_user" + ah_password: "access_test_user" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + register: result + failed_when: "'HTTP 403' not in result.msg" + + - name: try to create namespace, expected to fail + ah_namespace: + name: revoke_access_test + company: Automator Inc. + email: automator@redhat.com + description: The namespace for all things automation + ah_host: "{{ ah_host }}" + ah_username: "access_test_user" + ah_password: "access_test_user" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + register: result + failed_when: "'HTTP 403' not in result.msg" + + - name: give access + group_roles: + state: present + groups: + - revoke_access_test + role_list: + - roles: + - galaxy.collection_remote_owner + - roles: + - galaxy.content_admin + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: try to change the remote, will pass this time + collection_remote: + name: community-test-group-roles + url: https://galaxy.ansible.com/ + requirements: + - name: infra.ee_utilities + - name: infra.controller_configuration + ah_host: "{{ ah_host }}" + ah_username: "access_test_user" + ah_password: "access_test_user" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: try to create namespace, will pass this time + ah_namespace: + name: revoke_access_test + company: Automator Inc. + email: automator@redhat.com + description: The namespace for all things automation + ah_host: "{{ ah_host }}" + ah_username: "access_test_user" + ah_password: "access_test_user" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Delete the user + ah_user: + state: absent + username: access_test_user + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Delete the group + ah_group: + state: absent + name: revoke_access_test + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: delete the remote + collection_remote: + name: community-test-group-roles + url: https://beta-galaxy.ansible.com/ + state: absent + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: delete the namespace + ah_namespace: + name: revoke_access_test + state: absent + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false diff --git a/dev/galaxy_collection_plays_integration_tests/repo.yml b/dev/galaxy_collection_plays_integration_tests/repo.yml new file mode 100644 index 0000000000..5361d0339e --- /dev/null +++ b/dev/galaxy_collection_plays_integration_tests/repo.yml @@ -0,0 +1,63 @@ +--- +- name: Collection tests - Repo + hosts: localhost + connection: local + gather_facts: false + ignore_errors: true + collections: + - galaxy.galaxy + + pre_tasks: + - name: Include variables + ansible.builtin.include_vars: + file: vars/vars.yml + + tasks: + - name: create a collection remote + collection_remote: + name: community-infra + url: https://beta-galaxy.ansible.com/ + requirements: + - name: infra.ee_utilities + - name: infra.controller_configuration + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Configure remote from a file + collection_remote: + name: remote_req_file + url: https://galaxy.ansible.com/api/ + requirements_file: vars/collection_requirement_file.yml + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: create a collection repository + collection_repository: + name: collection-repo-community-infra + pulp_labels: + pipeline: "approved" + distribution: + name: "distribution" + state: present + remote: community-infra + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Sync community repo and wait up to 60 seconds + collection_repository_sync: + name: collection-repo-community-infra + wait: true + timeout: 60 + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" diff --git a/dev/galaxy_collection_plays_integration_tests/user.yml b/dev/galaxy_collection_plays_integration_tests/user.yml new file mode 100644 index 0000000000..f11a9b8452 --- /dev/null +++ b/dev/galaxy_collection_plays_integration_tests/user.yml @@ -0,0 +1,116 @@ +--- +- name: Galaxy + AH Collection Tests for User Automation + hosts: localhost + connection: local + gather_facts: false + ignore_errors: true + collections: + - galaxy.galaxy + + pre_tasks: + - name: Include variables + ansible.builtin.include_vars: + file: vars.yml + + tasks: + - name: Create a developers group + ah_group: + name: developers + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Add 3 new users who are developers + ah_user: + username: "dev_{{ item }}" + password: password!@3w6$% + first_name: Developer + last_name: "{{ item | capitalize }}" + groups: + - developers + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + loop: + - red + - green + - blue + + - name: Create an executives group + ah_group: + name: executives + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Create an omnipotent role with all permissions + ah_role: + name: galaxy.omnipotent + description: Manage anything and everything + perms: all + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + +# TODO: Add a test that permissions/roles can be added to a group after +# https://github.com/ansible/galaxy_collection/issues/179 is resolved. + + - name: Create new executive users + ah_user: + username: "{{ item }}" + password: executive!@3w6$% + is_superuser: true + email: "{{ item }}@redhat.com" + groups: + - executives + - developers + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + loop: + - ceo + - cfo + - cto + + - name: Delete the red developer + ah_user: + state: absent + username: dev_red + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + + - name: Delete the developers and executives groups + ah_group: + state: absent + name: "{{ item }}" + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false + loop: + - developers + - executives + + - name: Delete the omnipotent role + ah_role: + state: absent + name: galaxy.omnipotent + ah_host: "{{ ah_host }}" + ah_username: "{{ ah_username }}" + ah_password: "{{ ah_password }}" + ah_path_prefix: "{{ ah_path_prefix }}" + validate_certs: false diff --git a/dev/galaxy_collection_plays_integration_tests/vars/collection_requirement_file.yml b/dev/galaxy_collection_plays_integration_tests/vars/collection_requirement_file.yml new file mode 100644 index 0000000000..5c87117cdd --- /dev/null +++ b/dev/galaxy_collection_plays_integration_tests/vars/collection_requirement_file.yml @@ -0,0 +1,6 @@ +--- +collections: + - name: infra.ee_utilities + - name: infra.controller_configuration + - name: ansible.windows +... \ No newline at end of file diff --git a/dev/galaxy_collection_plays_integration_tests/vars/dispatch_vars.yml b/dev/galaxy_collection_plays_integration_tests/vars/dispatch_vars.yml new file mode 100644 index 0000000000..79605f2349 --- /dev/null +++ b/dev/galaxy_collection_plays_integration_tests/vars/dispatch_vars.yml @@ -0,0 +1,144 @@ +#--- +ah_configuration_working_dir: "test" +ah_validate_certs: false +ah_configuration_namespace_secure_logging: false + +ah_ee_registries: + - name: quay + url: https://quay.io/ + rate_limit: 100 + download_concurrency: 25 + tls_validation: false + - name: redhat + url: https://registry.redhat.io/v2/ + rate_limit: 100000 + download_concurrency: 25 + tls_validation: false + interval: 20 + timeout: 1100 + +ah_ee_repositories: + # Adding a Remote repository + - name: config_as_code_ee + description: The infra config as code official EE + registry: quay + upstream_name: redhat_cop/config_as_code_ee + include_tags: + - latest + - test_include + exclude_tags: + - test_exclude + wait: true + interval: 5 + timeout: 600 + +ah_namespaces: + - name: dispatch_test + company: Community Test + email: user@example.com + avatar_url: https://github.com/ansible/awx-logos/blob/master/awx/ui/client/assets/logo-header.svg + description: string + resources: "# Community\nA Namespace test with changes" + links: + - name: "Nothing" + url: "https://github.com/ansible/awx" + validate_certs: false + - name: infra + validate_certs: false + - name: test_namespace + validate_certs: false + - name: galaxy + validate_certs: false + +ah_repositories: + - name: dispatch_test + url: https://beta-galaxy.ansible.com/ + requirements: + - name: infra.ee_utilities + - name: infra.controller_configuration + wait: true + interval: 25 + timeout: 100 + validate_certs: false + +ah_collection_remotes: + - name: dispatch_test + url: https://beta-galaxy.ansible.com/ + requirements: + - name: infra.ee_utilities + - name: infra.controller_configuration + validate_certs: false + +ah_roles: + - name: galaxy.stuff.mcstuffins + description: dispatch_test + perms: + - add_user + - change_user + - delete_user + - view_user + - add_ansiblerepository + - add_collectionremote + validate_certs: false + - name: galaxy.stuff.mcstuffins + state: absent + validate_certs: false + +ah_groups: + - name: operators + validate_certs: false + - name: administrators + validate_certs: false + - name: managers + validate_certs: false + +ah_users: + # Ensure user operator1 exists (no group, no details) + - username: dispatch_test1 + validate_certs: false + # Ensure user admin1 exists (all details, two groups) + - username: dispatch_test2 + # Testing with UTF-8 characters + first_name: Czesława + last_name: Dąbrowski + email: cdabrowski@example.com + password: vs9mrD55NP + groups: + - operators + - administrators + validate_certs: false + # Testing user update\ + - username: dispatch_test3 + first_name: Róża + is_superuser: true + validate_certs: false + # Testing group membership + - username: dispatch_test4 + groups: operators + state: present + validate_certs: false + # Ensure operator1 is member of group operators and managers + - username: dispatch_test5 + groups: + - managers + append: true + validate_certs: false + # Ensure operator1 is member of group administrators only + - username: dispatch_test6 + groups: + - administrators + append: false + validate_certs: false + # Ensure operator1 is member of no group + - username: dispatch_test7 + groups: [] + append: false + validate_certs: false + # Testing password change + - username: dispatch_test8 + password: test123456 + validate_certs: false + - username: dispatch_test9 + state: absent + validate_certs: false +... \ No newline at end of file diff --git a/dev/galaxy_collection_plays_integration_tests/vars/vars.yml b/dev/galaxy_collection_plays_integration_tests/vars/vars.yml new file mode 100644 index 0000000000..9023539843 --- /dev/null +++ b/dev/galaxy_collection_plays_integration_tests/vars/vars.yml @@ -0,0 +1,10 @@ +#ah_host: http://localhost:5001 +#hub_host: localhost:5001 +#ah_username: iqe_admin +#ah_password: redhat +#ah_path_prefix: galaxy +ah_host: http://localhost:55001 +hub_host: localhost:55001 +ah_username: admin +ah_password: admin +ah_path_prefix: galaxy \ No newline at end of file