From 5b88860d84318216a650881f353a9e2cb83779e2 Mon Sep 17 00:00:00 2001 From: Chris Hammer Date: Tue, 28 Nov 2023 16:25:10 -0500 Subject: [PATCH] initial project commit --- .ansible-lint | 6 ++ .drone.yml | 87 ++++++++++++++++++ .gitignore | 4 + ansible.cfg | 26 ++++++ .../chhammer/known_bad/CHANGELOG.md | 0 .../chhammer/known_bad/README.md | 3 + .../chhammer/known_bad/galaxy.yml | 68 ++++++++++++++ .../chhammer/known_bad/meta/runtime.yml | 52 +++++++++++ .../chhammer/known_bad/plugins/README.md | 31 +++++++ .../chhammer/known_bad/roles/bad/README.md | 38 ++++++++ .../known_bad/roles/bad/defaults/main.yml | 2 + .../known_bad/roles/bad/handlers/main.yml | 2 + .../known_bad/roles/bad/meta/main.yml | 57 ++++++++++++ .../known_bad/roles/bad/tasks/main.yml | 9 ++ .../known_bad/roles/bad/tests/inventory | 2 + .../known_bad/roles/bad/tests/test.yml | 6 ++ .../known_bad/roles/bad/vars/main.yml | 2 + .../chhammer/known_good/CHANGELOG.md | 0 .../chhammer/known_good/README.md | 3 + .../chhammer/known_good/galaxy.yml | 68 ++++++++++++++ .../chhammer/known_good/meta/runtime.yml | 52 +++++++++++ .../chhammer/known_good/plugins/README.md | 31 +++++++ .../chhammer/known_good/roles/good/README.md | 38 ++++++++ .../known_good/roles/good/defaults/main.yml | 2 + .../known_good/roles/good/handlers/main.yml | 2 + .../known_good/roles/good/meta/main.yml | 57 ++++++++++++ .../known_good/roles/good/tasks/main.yml | 8 ++ .../known_good/roles/good/tests/inventory | 2 + .../known_good/roles/good/tests/test.yml | 6 ++ .../known_good/roles/good/vars/main.yml | 2 + files/chhammer-known_bad-1.0.2.tar.gz | Bin 0 -> 4846 bytes files/chhammer-known_good-1.0.2.tar.gz | Bin 0 -> 4749 bytes hosts | 1 + hub_approval.yml | 70 ++++++++++++++ requirements.yml | 3 + 35 files changed, 740 insertions(+) create mode 100644 .ansible-lint create mode 100644 .drone.yml create mode 100644 .gitignore create mode 100644 ansible.cfg create mode 100644 collections/ansible_collections/chhammer/known_bad/CHANGELOG.md create mode 100644 collections/ansible_collections/chhammer/known_bad/README.md create mode 100644 collections/ansible_collections/chhammer/known_bad/galaxy.yml create mode 100644 collections/ansible_collections/chhammer/known_bad/meta/runtime.yml create mode 100644 collections/ansible_collections/chhammer/known_bad/plugins/README.md create mode 100644 collections/ansible_collections/chhammer/known_bad/roles/bad/README.md create mode 100644 collections/ansible_collections/chhammer/known_bad/roles/bad/defaults/main.yml create mode 100644 collections/ansible_collections/chhammer/known_bad/roles/bad/handlers/main.yml create mode 100644 collections/ansible_collections/chhammer/known_bad/roles/bad/meta/main.yml create mode 100644 collections/ansible_collections/chhammer/known_bad/roles/bad/tasks/main.yml create mode 100644 collections/ansible_collections/chhammer/known_bad/roles/bad/tests/inventory create mode 100644 collections/ansible_collections/chhammer/known_bad/roles/bad/tests/test.yml create mode 100644 collections/ansible_collections/chhammer/known_bad/roles/bad/vars/main.yml create mode 100644 collections/ansible_collections/chhammer/known_good/CHANGELOG.md create mode 100644 collections/ansible_collections/chhammer/known_good/README.md create mode 100644 collections/ansible_collections/chhammer/known_good/galaxy.yml create mode 100644 collections/ansible_collections/chhammer/known_good/meta/runtime.yml create mode 100644 collections/ansible_collections/chhammer/known_good/plugins/README.md create mode 100644 collections/ansible_collections/chhammer/known_good/roles/good/README.md create mode 100644 collections/ansible_collections/chhammer/known_good/roles/good/defaults/main.yml create mode 100644 collections/ansible_collections/chhammer/known_good/roles/good/handlers/main.yml create mode 100644 collections/ansible_collections/chhammer/known_good/roles/good/meta/main.yml create mode 100644 collections/ansible_collections/chhammer/known_good/roles/good/tasks/main.yml create mode 100644 collections/ansible_collections/chhammer/known_good/roles/good/tests/inventory create mode 100644 collections/ansible_collections/chhammer/known_good/roles/good/tests/test.yml create mode 100644 collections/ansible_collections/chhammer/known_good/roles/good/vars/main.yml create mode 100644 files/chhammer-known_bad-1.0.2.tar.gz create mode 100644 files/chhammer-known_good-1.0.2.tar.gz create mode 100644 hosts create mode 100644 hub_approval.yml create mode 100644 requirements.yml diff --git a/.ansible-lint b/.ansible-lint new file mode 100644 index 0000000..3c92e90 --- /dev/null +++ b/.ansible-lint @@ -0,0 +1,6 @@ +skip_list: + - yaml[colons] + - yaml[empty-lines] + - yaml[line-length] + - no-changed-when + - ignore-errors diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..d13f94b --- /dev/null +++ b/.drone.yml @@ -0,0 +1,87 @@ +--- +kind: pipeline +type: docker +name: run_ansible_tests_fedora39 + +global-variables: + ansible_image : &ansible_image "gitea.thezengarden.net/podman/images/ansible-dev:latest" + ansible_inventory : &ansible_inventory "-i 127.0.0.1, --connection=local" + ansible_playbook : &ansible_playbook "hub_approval.yml" + +environment: + ANSIBLE_INVENTORY : *ansible_inventory + ANSIBLE_PLAYBOOK : *ansible_playbook + +trigger: + branch: + exclude: + - main + event: [push] + +steps: + - name: "ansible_environment_verify" + image: *ansible_image + commands: + - git log -1 + - ansible --version + - ansible-lint --version + + - name: "ansible_galaxy_requirements" + image: *ansible_image + commands: + - ansible-galaxy install -r requirements.yml + + - name: "ansible_lint" + image: *ansible_image + commands: + - ansible-lint --offline + + - name: "ansible_playbook_execution" + image: *ansible_image + commands: + - ansible-playbook -v $ANSIBLE_INVENTORY $ANSIBLE_PLAYBOOK + + +--- +kind: pipeline +type: docker +name: run_ansible_tests_centos9 + +global-variables: + ansible_image : &ansible_image "gitea.thezengarden.net/podman/images/ansible-dev:centos-stream9" + ansible_inventory : &ansible_inventory "-i 127.0.0.1, --connection=local" + ansible_playbook : &ansible_playbook "hub_approval.yml" + +environment: + ANSIBLE_INVENTORY : *ansible_inventory + ANSIBLE_PLAYBOOK : *ansible_playbook + +trigger: + branch: + exclude: + - main + event: [push] + +steps: + - name: "ansible_environment_verify" + image: *ansible_image + commands: + - git log -1 + - ansible --version + - ansible-lint --version + + - name: "ansible_galaxy_requirements" + image: *ansible_image + commands: + - ansible-galaxy install -r requirements.yml + + - name: "ansible_lint" + image: *ansible_image + commands: + - ansible-lint --offline + + - name: "ansible_playbook_execution" + image: *ansible_image + commands: + - ansible-playbook -v $ANSIBLE_INVENTORY $ANSIBLE_PLAYBOOK + diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..8320b83 --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +facts.d/ +collections/ansible_collections/ans* +collections/ansible_collections/infra* +.vscode diff --git a/ansible.cfg b/ansible.cfg new file mode 100644 index 0000000..33a3267 --- /dev/null +++ b/ansible.cfg @@ -0,0 +1,26 @@ +[defaults] +inventory = hosts +roles_path = roles +collections_path = collections +gathering = smart +gather_timeout = 300 +fact_path = facts.d +fact_caching = jsonfile +fact_caching_connection = facts.d +fact_caching_timeout = 300 +retry_files_enabled = False +forks = 40 +timeout = 30 +host_key_checking = False +display_skipped_hosts = False +bin_ansible_callbacks = True +callback_whitelist = ansible.posix.profile_tasks, ansible.posix.timer +deprecation_warnings = False +command_warnings = False +# strategy = free + + +[ssh_connection] +pipelining = True +ssh_args = -o ControlMaster=auto -o ControlPersist=60s -o PreferredAuthentications=publickey + diff --git a/collections/ansible_collections/chhammer/known_bad/CHANGELOG.md b/collections/ansible_collections/chhammer/known_bad/CHANGELOG.md new file mode 100644 index 0000000..e69de29 diff --git a/collections/ansible_collections/chhammer/known_bad/README.md b/collections/ansible_collections/chhammer/known_bad/README.md new file mode 100644 index 0000000..6038a06 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/README.md @@ -0,0 +1,3 @@ +# Ansible Collection - rhc.known_bad + +Documentation for the collection. diff --git a/collections/ansible_collections/chhammer/known_bad/galaxy.yml b/collections/ansible_collections/chhammer/known_bad/galaxy.yml new file mode 100644 index 0000000..e91ae8e --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/galaxy.yml @@ -0,0 +1,68 @@ +### REQUIRED +# The namespace of the collection. This can be a company/brand/organization or product namespace under which all +# content lives. May only contain alphanumeric lowercase characters and underscores. Namespaces cannot start with +# underscores or numbers and cannot contain consecutive underscores +namespace: chhammer + +# The name of the collection. Has the same character restrictions as 'namespace' +name: known_bad + +# The version of the collection. Must be compatible with semantic versioning +version: 1.0.2 + +# The path to the Markdown (.md) readme file. This path is relative to the root of the collection +readme: README.md + +# A list of the collection's content authors. Can be just the name or in the format 'Full Name (url) +# @nicks:irc/im.site#channel' +authors: + - 'Chris Hammer ' + + +### OPTIONAL but strongly recommended +# A short summary description of the collection +description: this is known to fail ansible-lint + +# Either a single license or a list of licenses for content inside of a collection. Ansible Galaxy currently only +# accepts L(SPDX,https://spdx.org/licenses/) licenses. This key is mutually exclusive with 'license_file' +license: + - GPL-2.0-or-later + +# The path to the license file for the collection. This path is relative to the root of the collection. This key is +# mutually exclusive with 'license' +license_file: '' + +# A list of tags you want to associate with the collection for indexing/searching. A tag name has the same character +# requirements as 'namespace' and 'name' +tags: [linux] + +# Collections that this collection requires to be installed for it to be usable. The key of the dict is the +# collection label 'namespace.name'. The value is a version range +# L(specifiers,https://python-semanticversion.readthedocs.io/en/latest/#requirement-specification). Multiple version +# range specifiers can be set and are separated by ',' +dependencies: {} + +# The URL of the originating SCM repository +repository: http://example.com/repository + +# The URL to any online docs +documentation: http://docs.example.com + +# The URL to the homepage of the collection/project +homepage: http://example.com + +# The URL to the collection issue tracker +issues: http://example.com/issue/tracker + +# A list of file glob-like patterns used to filter any files or directories that should not be included in the build +# artifact. A pattern is matched from the relative path of the file or directory of the collection directory. This +# uses 'fnmatch' to match the files or directories. Some directories and files like 'galaxy.yml', '*.pyc', '*.retry', +# and '.git' are always filtered. Mutually exclusive with 'manifest' +build_ignore: [] + +# A dict controlling use of manifest directives used in building the collection artifact. The key 'directives' is a +# list of MANIFEST.in style +# L(directives,https://packaging.python.org/en/latest/guides/using-manifest-in/#manifest-in-commands). The key +# 'omit_default_directives' is a boolean that controls whether the default directives are used. Mutually exclusive +# with 'build_ignore' +# manifest: null diff --git a/collections/ansible_collections/chhammer/known_bad/meta/runtime.yml b/collections/ansible_collections/chhammer/known_bad/meta/runtime.yml new file mode 100644 index 0000000..2fe301c --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/meta/runtime.yml @@ -0,0 +1,52 @@ +--- +# Collections must specify a minimum required ansible version to upload +# to galaxy +requires_ansible: '>=2.9.10' + +# Content that Ansible needs to load from another location or that has +# been deprecated/removed +# plugin_routing: +# action: +# redirected_plugin_name: +# redirect: ns.col.new_location +# deprecated_plugin_name: +# deprecation: +# removal_version: "4.0.0" +# warning_text: | +# See the porting guide on how to update your playbook to +# use ns.col.another_plugin instead. +# removed_plugin_name: +# tombstone: +# removal_version: "2.0.0" +# warning_text: | +# See the porting guide on how to update your playbook to +# use ns.col.another_plugin instead. +# become: +# cache: +# callback: +# cliconf: +# connection: +# doc_fragments: +# filter: +# httpapi: +# inventory: +# lookup: +# module_utils: +# modules: +# netconf: +# shell: +# strategy: +# terminal: +# test: +# vars: + +# Python import statements that Ansible needs to load from another location +# import_redirection: +# ansible_collections.ns.col.plugins.module_utils.old_location: +# redirect: ansible_collections.ns.col.plugins.module_utils.new_location + +# Groups of actions/modules that take a common set of options +# action_groups: +# group_name: +# - module1 +# - module2 diff --git a/collections/ansible_collections/chhammer/known_bad/plugins/README.md b/collections/ansible_collections/chhammer/known_bad/plugins/README.md new file mode 100644 index 0000000..34cd30a --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/plugins/README.md @@ -0,0 +1,31 @@ +# Collections Plugins Directory + +This directory can be used to ship various plugins inside an Ansible collection. Each plugin is placed in a folder that +is named after the type of plugin it is in. It can also include the `module_utils` and `modules` directory that +would contain module utils and modules respectively. + +Here is an example directory of the majority of plugins currently supported by Ansible: + +``` +└── plugins + ├── action + ├── become + ├── cache + ├── callback + ├── cliconf + ├── connection + ├── filter + ├── httpapi + ├── inventory + ├── lookup + ├── module_utils + ├── modules + ├── netconf + ├── shell + ├── strategy + ├── terminal + ├── test + └── vars +``` + +A full list of plugin types can be found at [Working With Plugins](https://docs.ansible.com/ansible-core/2.14/plugins/plugins.html). diff --git a/collections/ansible_collections/chhammer/known_bad/roles/bad/README.md b/collections/ansible_collections/chhammer/known_bad/roles/bad/README.md new file mode 100644 index 0000000..225dd44 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/roles/bad/README.md @@ -0,0 +1,38 @@ +Role Name +========= + +A brief description of the role goes here. + +Requirements +------------ + +Any pre-requisites that may not be covered by Ansible itself or the role should be mentioned here. For instance, if the role uses the EC2 module, it may be a good idea to mention in this section that the boto package is required. + +Role Variables +-------------- + +A description of the settable variables for this role should go here, including any variables that are in defaults/main.yml, vars/main.yml, and any variables that can/should be set via parameters to the role. Any variables that are read from other roles and/or the global scope (ie. hostvars, group vars, etc.) should be mentioned here as well. + +Dependencies +------------ + +A list of other roles hosted on Galaxy should go here, plus any details in regards to parameters that may need to be set for other roles, or variables that are used from other roles. + +Example Playbook +---------------- + +Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too: + + - hosts: servers + roles: + - { role: username.rolename, x: 42 } + +License +------- + +BSD + +Author Information +------------------ + +An optional section for the role authors to include contact information, or a website (HTML is not allowed). diff --git a/collections/ansible_collections/chhammer/known_bad/roles/bad/defaults/main.yml b/collections/ansible_collections/chhammer/known_bad/roles/bad/defaults/main.yml new file mode 100644 index 0000000..be0afad --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/roles/bad/defaults/main.yml @@ -0,0 +1,2 @@ +--- +# defaults file for bad diff --git a/collections/ansible_collections/chhammer/known_bad/roles/bad/handlers/main.yml b/collections/ansible_collections/chhammer/known_bad/roles/bad/handlers/main.yml new file mode 100644 index 0000000..97543fc --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/roles/bad/handlers/main.yml @@ -0,0 +1,2 @@ +--- +# handlers file for bad diff --git a/collections/ansible_collections/chhammer/known_bad/roles/bad/meta/main.yml b/collections/ansible_collections/chhammer/known_bad/roles/bad/meta/main.yml new file mode 100644 index 0000000..df2eda1 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/roles/bad/meta/main.yml @@ -0,0 +1,57 @@ +galaxy_info: + author: Chris Hammer + description: Doesn't do anything but fail + company: Red Hat + + # If the issue tracker for your role is not on github, uncomment the + # next line and provide a value + # issue_tracker_url: http://example.com/issue/tracker + + # Choose a valid license ID from https://spdx.org - some suggested licenses: + # - BSD-3-Clause (default) + # - MIT + # - GPL-2.0-or-later + # - GPL-3.0-only + # - Apache-2.0 + # - CC-BY-4.0 + license: GPL-2.0-or-later + + min_ansible_version: '2.9' + + # If this a Container Enabled role, provide the minimum Ansible Container version. + # min_ansible_container_version: + + # + # Provide a list of supported platforms, and for each platform a list of versions. + # If you don't wish to enumerate all versions for a particular platform, use 'all'. + # To view available platforms and versions (or releases), visit: + # https://galaxy.ansible.com/api/v1/platforms/ + # + # platforms: + # - name: Fedora + # versions: + # - all + # - 25 + # - name: SomePlatform + # versions: + # - all + # - 1.0 + # - 7 + # - 99.99 + + platforms: + - name: Fedora + versions: + - all + + galaxy_tags: [] + # List tags for your role here, one per line. A tag is a keyword that describes + # and categorizes the role. Users find roles by searching for tags. Be sure to + # remove the '[]' above, if you add tags to this list. + # + # NOTE: A tag is limited to a single word comprised of alphanumeric characters. + # Maximum 20 tags per role. + +dependencies: [] + # List your role dependencies here, one per line. Be sure to remove the '[]' above, + # if you add dependencies to this list. diff --git a/collections/ansible_collections/chhammer/known_bad/roles/bad/tasks/main.yml b/collections/ansible_collections/chhammer/known_bad/roles/bad/tasks/main.yml new file mode 100644 index 0000000..c397587 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/roles/bad/tasks/main.yml @@ -0,0 +1,9 @@ +--- +- name: Simply say hello whenever we're called...but cause lint to fail too. + debug: + msg: Hello world! + + +- name: This is another task for a version bump + debug: + msg: "I will also fail lint because i didnt provide the FQCN. :)" diff --git a/collections/ansible_collections/chhammer/known_bad/roles/bad/tests/inventory b/collections/ansible_collections/chhammer/known_bad/roles/bad/tests/inventory new file mode 100644 index 0000000..878877b --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/roles/bad/tests/inventory @@ -0,0 +1,2 @@ +localhost + diff --git a/collections/ansible_collections/chhammer/known_bad/roles/bad/tests/test.yml b/collections/ansible_collections/chhammer/known_bad/roles/bad/tests/test.yml new file mode 100644 index 0000000..d9cff10 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/roles/bad/tests/test.yml @@ -0,0 +1,6 @@ +--- +- name: Test the bad role + hosts: localhost + remote_user: root + roles: + - bad diff --git a/collections/ansible_collections/chhammer/known_bad/roles/bad/vars/main.yml b/collections/ansible_collections/chhammer/known_bad/roles/bad/vars/main.yml new file mode 100644 index 0000000..75a7878 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_bad/roles/bad/vars/main.yml @@ -0,0 +1,2 @@ +--- +# vars file for bad diff --git a/collections/ansible_collections/chhammer/known_good/CHANGELOG.md b/collections/ansible_collections/chhammer/known_good/CHANGELOG.md new file mode 100644 index 0000000..e69de29 diff --git a/collections/ansible_collections/chhammer/known_good/README.md b/collections/ansible_collections/chhammer/known_good/README.md new file mode 100644 index 0000000..10bdcd0 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/README.md @@ -0,0 +1,3 @@ +# Ansible Collection - rhc.known_good + +Documentation for the collection. diff --git a/collections/ansible_collections/chhammer/known_good/galaxy.yml b/collections/ansible_collections/chhammer/known_good/galaxy.yml new file mode 100644 index 0000000..6dc3f0e --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/galaxy.yml @@ -0,0 +1,68 @@ +### REQUIRED +# The namespace of the collection. This can be a company/brand/organization or product namespace under which all +# content lives. May only contain alphanumeric lowercase characters and underscores. Namespaces cannot start with +# underscores or numbers and cannot contain consecutive underscores +namespace: chhammer + +# The name of the collection. Has the same character restrictions as 'namespace' +name: known_good + +# The version of the collection. Must be compatible with semantic versioning +version: 1.0.2 + +# The path to the Markdown (.md) readme file. This path is relative to the root of the collection +readme: README.md + +# A list of the collection's content authors. Can be just the name or in the format 'Full Name (url) +# @nicks:irc/im.site#channel' +authors: + - 'Chris Hammer ' + + +### OPTIONAL but strongly recommended +# A short summary description of the collection +description: a simple collection to verify ansible-lint + +# Either a single license or a list of licenses for content inside of a collection. Ansible Galaxy currently only +# accepts L(SPDX,https://spdx.org/licenses/) licenses. This key is mutually exclusive with 'license_file' +license: + - GPL-2.0-or-later + +# The path to the license file for the collection. This path is relative to the root of the collection. This key is +# mutually exclusive with 'license' +license_file: '' + +# A list of tags you want to associate with the collection for indexing/searching. A tag name has the same character +# requirements as 'namespace' and 'name' +tags: [linux] + +# Collections that this collection requires to be installed for it to be usable. The key of the dict is the +# collection label 'namespace.name'. The value is a version range +# L(specifiers,https://python-semanticversion.readthedocs.io/en/latest/#requirement-specification). Multiple version +# range specifiers can be set and are separated by ',' +dependencies: {} + +# The URL of the originating SCM repository +repository: http://example.com/repository + +# The URL to any online docs +documentation: http://docs.example.com + +# The URL to the homepage of the collection/project +homepage: http://example.com + +# The URL to the collection issue tracker +issues: http://example.com/issue/tracker + +# A list of file glob-like patterns used to filter any files or directories that should not be included in the build +# artifact. A pattern is matched from the relative path of the file or directory of the collection directory. This +# uses 'fnmatch' to match the files or directories. Some directories and files like 'galaxy.yml', '*.pyc', '*.retry', +# and '.git' are always filtered. Mutually exclusive with 'manifest' +build_ignore: [] + +# A dict controlling use of manifest directives used in building the collection artifact. The key 'directives' is a +# list of MANIFEST.in style +# L(directives,https://packaging.python.org/en/latest/guides/using-manifest-in/#manifest-in-commands). The key +# 'omit_default_directives' is a boolean that controls whether the default directives are used. Mutually exclusive +# with 'build_ignore' +# manifest: null diff --git a/collections/ansible_collections/chhammer/known_good/meta/runtime.yml b/collections/ansible_collections/chhammer/known_good/meta/runtime.yml new file mode 100644 index 0000000..2fe301c --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/meta/runtime.yml @@ -0,0 +1,52 @@ +--- +# Collections must specify a minimum required ansible version to upload +# to galaxy +requires_ansible: '>=2.9.10' + +# Content that Ansible needs to load from another location or that has +# been deprecated/removed +# plugin_routing: +# action: +# redirected_plugin_name: +# redirect: ns.col.new_location +# deprecated_plugin_name: +# deprecation: +# removal_version: "4.0.0" +# warning_text: | +# See the porting guide on how to update your playbook to +# use ns.col.another_plugin instead. +# removed_plugin_name: +# tombstone: +# removal_version: "2.0.0" +# warning_text: | +# See the porting guide on how to update your playbook to +# use ns.col.another_plugin instead. +# become: +# cache: +# callback: +# cliconf: +# connection: +# doc_fragments: +# filter: +# httpapi: +# inventory: +# lookup: +# module_utils: +# modules: +# netconf: +# shell: +# strategy: +# terminal: +# test: +# vars: + +# Python import statements that Ansible needs to load from another location +# import_redirection: +# ansible_collections.ns.col.plugins.module_utils.old_location: +# redirect: ansible_collections.ns.col.plugins.module_utils.new_location + +# Groups of actions/modules that take a common set of options +# action_groups: +# group_name: +# - module1 +# - module2 diff --git a/collections/ansible_collections/chhammer/known_good/plugins/README.md b/collections/ansible_collections/chhammer/known_good/plugins/README.md new file mode 100644 index 0000000..34cd30a --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/plugins/README.md @@ -0,0 +1,31 @@ +# Collections Plugins Directory + +This directory can be used to ship various plugins inside an Ansible collection. Each plugin is placed in a folder that +is named after the type of plugin it is in. It can also include the `module_utils` and `modules` directory that +would contain module utils and modules respectively. + +Here is an example directory of the majority of plugins currently supported by Ansible: + +``` +└── plugins + ├── action + ├── become + ├── cache + ├── callback + ├── cliconf + ├── connection + ├── filter + ├── httpapi + ├── inventory + ├── lookup + ├── module_utils + ├── modules + ├── netconf + ├── shell + ├── strategy + ├── terminal + ├── test + └── vars +``` + +A full list of plugin types can be found at [Working With Plugins](https://docs.ansible.com/ansible-core/2.14/plugins/plugins.html). diff --git a/collections/ansible_collections/chhammer/known_good/roles/good/README.md b/collections/ansible_collections/chhammer/known_good/roles/good/README.md new file mode 100644 index 0000000..225dd44 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/roles/good/README.md @@ -0,0 +1,38 @@ +Role Name +========= + +A brief description of the role goes here. + +Requirements +------------ + +Any pre-requisites that may not be covered by Ansible itself or the role should be mentioned here. For instance, if the role uses the EC2 module, it may be a good idea to mention in this section that the boto package is required. + +Role Variables +-------------- + +A description of the settable variables for this role should go here, including any variables that are in defaults/main.yml, vars/main.yml, and any variables that can/should be set via parameters to the role. Any variables that are read from other roles and/or the global scope (ie. hostvars, group vars, etc.) should be mentioned here as well. + +Dependencies +------------ + +A list of other roles hosted on Galaxy should go here, plus any details in regards to parameters that may need to be set for other roles, or variables that are used from other roles. + +Example Playbook +---------------- + +Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too: + + - hosts: servers + roles: + - { role: username.rolename, x: 42 } + +License +------- + +BSD + +Author Information +------------------ + +An optional section for the role authors to include contact information, or a website (HTML is not allowed). diff --git a/collections/ansible_collections/chhammer/known_good/roles/good/defaults/main.yml b/collections/ansible_collections/chhammer/known_good/roles/good/defaults/main.yml new file mode 100644 index 0000000..ff228b3 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/roles/good/defaults/main.yml @@ -0,0 +1,2 @@ +--- +# defaults file for good diff --git a/collections/ansible_collections/chhammer/known_good/roles/good/handlers/main.yml b/collections/ansible_collections/chhammer/known_good/roles/good/handlers/main.yml new file mode 100644 index 0000000..60d4d73 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/roles/good/handlers/main.yml @@ -0,0 +1,2 @@ +--- +# handlers file for good diff --git a/collections/ansible_collections/chhammer/known_good/roles/good/meta/main.yml b/collections/ansible_collections/chhammer/known_good/roles/good/meta/main.yml new file mode 100644 index 0000000..c6065db --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/roles/good/meta/main.yml @@ -0,0 +1,57 @@ +galaxy_info: + author: Chris Hammer + description: Doesn't do anything + company: Red Hat + + # If the issue tracker for your role is not on github, uncomment the + # next line and provide a value + # issue_tracker_url: http://example.com/issue/tracker + + # Choose a valid license ID from https://spdx.org - some suggested licenses: + # - BSD-3-Clause (default) + # - MIT + # - GPL-2.0-or-later + # - GPL-3.0-only + # - Apache-2.0 + # - CC-BY-4.0 + license: GPL-2.0-or-later + + min_ansible_version: '2.9' + + # If this a Container Enabled role, provide the minimum Ansible Container version. + # min_ansible_container_version: + + # + # Provide a list of supported platforms, and for each platform a list of versions. + # If you don't wish to enumerate all versions for a particular platform, use 'all'. + # To view available platforms and versions (or releases), visit: + # https://galaxy.ansible.com/api/v1/platforms/ + # + # platforms: + # - name: Fedora + # versions: + # - all + # - 25 + # - name: SomePlatform + # versions: + # - all + # - 1.0 + # - 7 + # - 99.99 + + platforms: + - name: Fedora + versions: + - all + + galaxy_tags: [] + # List tags for your role here, one per line. A tag is a keyword that describes + # and categorizes the role. Users find roles by searching for tags. Be sure to + # remove the '[]' above, if you add tags to this list. + # + # NOTE: A tag is limited to a single word comprised of alphanumeric characters. + # Maximum 20 tags per role. + +dependencies: [] + # List your role dependencies here, one per line. Be sure to remove the '[]' above, + # if you add dependencies to this list. diff --git a/collections/ansible_collections/chhammer/known_good/roles/good/tasks/main.yml b/collections/ansible_collections/chhammer/known_good/roles/good/tasks/main.yml new file mode 100644 index 0000000..4bfed25 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/roles/good/tasks/main.yml @@ -0,0 +1,8 @@ +--- +- name: Simply say hello whenever we're called + ansible.builtin.debug: + msg: Hello world! + +- name: This is another good task for version bump + ansible.builtin.debug: + msg: "I like to play with things." diff --git a/collections/ansible_collections/chhammer/known_good/roles/good/tests/inventory b/collections/ansible_collections/chhammer/known_good/roles/good/tests/inventory new file mode 100644 index 0000000..878877b --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/roles/good/tests/inventory @@ -0,0 +1,2 @@ +localhost + diff --git a/collections/ansible_collections/chhammer/known_good/roles/good/tests/test.yml b/collections/ansible_collections/chhammer/known_good/roles/good/tests/test.yml new file mode 100644 index 0000000..de130d2 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/roles/good/tests/test.yml @@ -0,0 +1,6 @@ +--- +- name: Test the good role + hosts: localhost + remote_user: root + roles: + - good diff --git a/collections/ansible_collections/chhammer/known_good/roles/good/vars/main.yml b/collections/ansible_collections/chhammer/known_good/roles/good/vars/main.yml new file mode 100644 index 0000000..3332854 --- /dev/null +++ b/collections/ansible_collections/chhammer/known_good/roles/good/vars/main.yml @@ -0,0 +1,2 @@ +--- +# vars file for good diff --git a/files/chhammer-known_bad-1.0.2.tar.gz b/files/chhammer-known_bad-1.0.2.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..386527e25f2476d396ee9c06256b80fb5ecad90c GIT binary patch literal 4846 zcmVR;{t{PGN{!m@E))|jKs%*y>`)=zhm70J6C~=1(cmz4)S#PTDA@cK{E>CjZ zASr1yisQ-7NUjK7iAMy12GBq^(9H(=&C|E9o}a$|VEtXm^1=Op4G{Xi{tK}A*YN`X zf#V0Bk;FAM5~H)zBK6^58Jx(})}~Srmdbxh&7}GLuJB0;%Mvqzj=c z$^;}FvH6@X7NR~n9$sPUc_}Z;vy}2K`9jnRu;3fVvMskurEN2pwSv?i;E^1i%IaCM#>Bf>ql8ojBp{2^xLX4qo)1fSKCQ2oiSYNz*J$5a7EbDPW8|eD7fT3=xDq87CCddi?$ghGA1bNxM%Gu@nt9Vy)5%19q>HK$*xkumh7OHn?Lw3d z9eU80fplf973^})k~06u5v$136H2L^7yY83CU zj^C00QRGC|<-Z*Tkz?fluH-*5>>x}(Y0)?ExTU#jjkkGT_es}zdk}#)8GH3+oi{ae zZd6tk?JO_V9;%#NUtG4yvd;;#Ez&Fwd^>hLCy9NJIsr`rnh7C1Zu2k;s1v0;%7RER zoANjjAxlEx__4!%5oe)KkG`z^xFYP5UUyC>;n)H762^Snjy(~=BEZ5RifxxCp)aC@ zrmz_lK}rMH&Jx!SnNKtBIS%E48)RQdr&{6+-yxxNg_B`pwChSITx7H@8nxfrCkvXF z*43i8tJ&hFHn&+6#nkf?SS+%{p|%Z^A@pq6I{2CIdw~;2F^hdWO1S4a0kB~hC7JDH zp?!4Qo;0xe*%J|U)swuufQ{g=Gr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&JwJevkE}`LPjra&H z_~+UiLf(t+s}>%TM@P_Ei{H6`ID-#p#qp54b_1??lXQFk8o5YSBTMo5-nn0C?^40!&>e=CD-1u2BBkuSe=2e&%dCHpWhvIC5tr;N ztLaSpzjsMlUNoZae&cC>TIJotGPZ8_SU|hms{7qJsGq@HE!28S|4@o%)dYnfXZxQG z-exfC5kjrNt+W`PRMY)Jx9TY}-Mg!1j!y0iBrOz%vbx>3=0d>LAvqhEWJ!?KjSowa zV)Y}@jexS&J8Q{;FPUnSGpD!4c8x^=+Y9t7SNgnsS9;RZwfF3&=XewVZy5o)p#L^{ zjB96NlrCMFGwqz-kA(hxjS0s6P&pgVX8&ZsfB^#r3>YwAz<>b*1`HT5V8DO@0|pEj UFkrxdf!)IY0~S*7gaGgW0Hl=hhX4Qo literal 0 HcmV?d00001 diff --git a/files/chhammer-known_good-1.0.2.tar.gz b/files/chhammer-known_good-1.0.2.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..b236aaad08eb0a2b09bc267ec9dd8eb26f4159ec GIT binary patch literal 4749 zcmV;85_0VyiwFpDO=e{R|6^!qVQpv2a01wBQQvCZEY{~?0Gg&>yLWRWaZ6T2&{zy*kcK>Y>S{EPi4 z+`~cW;~?rwy3MKqRQ+234&C#Uy(T% z3qm<0?9KkR>!spnOFS)EPmn(6cl-UvV=f5MLIcsiAI?W}GDr2Yi2X#Zr^ z6au|a_|U)inE%>vHY2S=>-k^yA>YrcY{LoDb^UmH{Ot9qGdESWWV*sw7FBn(D#W;; zO|fWAQwS2pd{J_=>L_Y!1dT27B_fq5vXUPGj#i^C3(70O2kg(^zB=+8_o!};O40%i zhKfwiv%Dx}_NpsO(|`r97_Vr-Wg|cSV*0YEMbXyHQnqT=wu{Ml%&&-So9y;@ErUi= z({9eImh?R_WguNRYXx=gSv}_qGUc};*LeydI@P4xs#iab+lJ6{)k)dvec83MIjM@A zi?;9R$8{$7{^hIFcS?WgI`Ve8P(P^5Dv8d{MK?d|e-Ja`h0(R2O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u2oeiUi+qX55cRzec-4QIdH7(n zj5)L@Yr+5zJnNX=Ba>b9q2MRz;4j~LPU>LyV5DlST3)p}B2pjvOU6=CVR|Gw9UiIw zShT!n;xieQLq|t1~Ms<-rm2qo@b)1EB@);d0%PoGEVEhJCxAb@K}}^q37nU zENETj=B2JGzQ#tZre}FWrYioOPRfh2<&A!xwe5l|3jH!%t=6w4w7XmAXC0vK40yE^ z>nY}?;_a#lLVldxJhqJtYHtuitst$W?B7JIpQLwxB8BelvYp8wcXLTvC=6v)yYDQ8 zfJ-Ae>xE<>h>`a*x>6~Q83{cC!ddUEQLy~#Mb|_ z4Y=<6d8@erJyYfvSgNCuirU5ccNr>NhPqbqtHDGRvqFXKF6vGgmx~OVEu_T`IeU|G zWxhG+6zpu&8{@JNp(X}3%E1`q+P^cBk(a^BVu<7|*TJ0Ibq2tz*Ssmz^!v3RZx}d&BlgH*H~Lz@N(&lMlWPU zauw5T2*tg^Yhu06$=~ayXqT&|3q-r70n1xPTk96mkcN(C%bs3ftbh3MVf5Rtzy9{? zKj2?qOnqMCw_pEhQnh)yk*Hl78;Q!daU)GTIX08Ew_`JPaC>b0pq(8XiN@=(kvh0P zHqx~pWFv8XFrM9izM}%OTdh zVNA)VqL-As?tpzri+=iB-JDB**572PIwNU6KasQ&lku3Hhf&~i}ELgB$;ZE>>3g4%g0Pp|+-v!LY literal 0 HcmV?d00001 diff --git a/hosts b/hosts new file mode 100644 index 0000000..03cac36 --- /dev/null +++ b/hosts @@ -0,0 +1 @@ +localhost ansible_connection=local diff --git a/hub_approval.yml b/hub_approval.yml new file mode 100644 index 0000000..e339b09 --- /dev/null +++ b/hub_approval.yml @@ -0,0 +1,70 @@ +- name: Test collection upload and approval + hosts: localhost + connection: local + become: false + gather_facts: false + + + vars: + __pah_host : 10.10.42.132 + __pah_token : e992a78e94cfe9ba8c21b65cb62a20e6dee43104 + __pah_namespace : chhammer + __pause_seconds : 10 + + + tasks: + - name: Upload known_good collection into Private Automation Hub + # Using `ah_collection` for uploading collections will default + # to auto-approving the collection. You must set `auto_approve: False` + # in order to hold collection for approval review + infra.ah_configuration.ah_collection: + validate_certs : false + ah_host : "{{ __pah_host }}" + ah_token : "{{ __pah_token }}" + path : "files/chhammer-known_good-1.0.2.tar.gz" + namespace : "{{ __pah_namespace }}" + name : known_good + + # Example with `auto_approve` set to `false`: + ############################################# + # - name: Upload known_bad collection into Private Automation Hub + # infra.ah_configuration.ah_collection: + # validate_certs : false + # ah_host : "{{ __pah_host }}" + # ah_token : "{{ __pah_token }}" + # path : "files/chhammer-known_bad-1.0.2.tar.gz" + # namespace : "{{ __pah_namespace }}" + # name : known_bad + # auto_approve : false + + + # Using `ah_collection_upload` for uploading collections will not + # auto-approve collections, likewise, there are no parameters for managing + # approval state via this module. + # + # Also, this does not seem to be idempotent like `ah_collection` module, + # hence the ignore errors. If the collection is already present or awaiting + # approval, this will return an error. + - name: Upload known_bad collection into Private Automation Hub + infra.ah_configuration.ah_collection_upload: + validate_certs : false + ah_host : "{{ __pah_host }}" + ah_token : "{{ __pah_token }}" + path : "files/chhammer-known_bad-1.0.2.tar.gz" + ignore_errors: true + + + - name: After a delay approve the known_bad collection + block: + - name: Create a delay to verify uploaded collection is waiting for approval + ansible.builtin.pause: + seconds: "{{ __pause_seconds }}" + + - name: Approve the known_bad collection + infra.ah_configuration.ah_approval: + validate_certs : false + ah_host : "{{ __pah_host }}" + ah_token : "{{ __pah_token }}" + namespace : "{{ __pah_namespace }}" + name : known_bad + version : 1.0.2 diff --git a/requirements.yml b/requirements.yml new file mode 100644 index 0000000..1b2d7aa --- /dev/null +++ b/requirements.yml @@ -0,0 +1,3 @@ +collections: + - ansible.posix + - infra.ah_configuration