Skip to content
This repository has been archived by the owner on Nov 23, 2020. It is now read-only.

Commit

Permalink
Problem: Ansible gives a poor error message when its version is too old
Browse files Browse the repository at this point in the history
and it sees new syntax.

Solution: Add a pre_task to check the ansible version,
and use yamllint and ansible-lint exceptions from ansible-pulp.

Also:
Update submodules (unrelated)
Add commneted out config setting for pulp-rpm

re: #5558
Add ansible-pulp logic to grab epel-release from the internet
https://pulp.plan.io/issues/5558

[noissue]
  • Loading branch information
mikedep333 committed Oct 9, 2019
1 parent 67677e7 commit 2ffc6ce
Show file tree
Hide file tree
Showing 9 changed files with 25 additions and 3 deletions.
1 change: 1 addition & 0 deletions .ansible-lint
1 change: 1 addition & 0 deletions .yamllint
2 changes: 1 addition & 1 deletion ansible-pulp
2 changes: 2 additions & 0 deletions example.dev-config.yml
Expand Up @@ -30,5 +30,7 @@ developer_user: "vagrant"
developer_user_home: "/home/vagrant"
pulp_plugin_source_dir: "/home/vagrant/devel/pulpcore-plugin"
pulp_source_dir: "/home/vagrant/devel/pulpcore"
# Uncomment if using pulp-rpm
#pulp_use_system_wide_pkgs: true
pulp_settings:
secret_key: "unsafe_default"
3 changes: 3 additions & 0 deletions example.user-config.yml
Expand Up @@ -11,5 +11,8 @@ pulp_install_plugins:
# pulp-rpm:
# prereq_role: "/home/vagrant/devel/pulp-rpm-prerequisites"
pulp-file: {}

# Uncomment if using pulp-rpm
#pulp_use_system_wide_pkgs: true
pulp_settings:
secret_key: "unsafe_default"
8 changes: 8 additions & 0 deletions playbooks/source-install.yml
Expand Up @@ -9,6 +9,14 @@
with_first_found: "{{ paths_to_vars_files }}"
- name: Set up Vagrant machine for source installs
include: ../vagrant/vagrant-pretask.yml

# The version string below is the highest of all those in roles' metadata:
# "min_ansible_version". It needs to be kept manually up-to-date.
- name: Verify Ansible meets min required version
assert:
that: "ansible_version.full is version_compare('2.8', '>=')"
msg: >
"You must update Ansible to at least 2.8 to use this version of Pulp 3 Installer."
roles:
- pulp-database
- pulp-workers
Expand Down
7 changes: 7 additions & 0 deletions playbooks/user-sandbox.yml
Expand Up @@ -8,6 +8,13 @@
- include_vars: "{{ item }}"
with_first_found: "{{ paths_to_vars_files }}"

# The version string below is the highest of all those in roles' metadata:
# "min_ansible_version". It needs to be kept manually up-to-date.
- name: Verify Ansible meets min required version
assert:
that: "ansible_version.full is version_compare('2.8', '>=')"
msg: >
"You must update Ansible to at least 2.8 to use this version of Pulp 3 Installer."
roles:
- pulp-database
- pulp-workers
Expand Down
2 changes: 1 addition & 1 deletion pulp-ci

0 comments on commit 2ffc6ce

Please sign in to comment.