Skip to content

Commit

Permalink
Merge pull request #386 from jturel/sat_69
Browse files Browse the repository at this point in the history
Add support for Satellite 6.9
  • Loading branch information
jturel authored Jun 14, 2021
2 parents bca1b16 + a2042ce commit 0fd2377
Show file tree
Hide file tree
Showing 9 changed files with 57 additions and 14 deletions.
25 changes: 19 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Throughout this documentation, ensure that you understand the following terminol
- 6.6
- 6.7
- 6.8
- 6.9

#### What you need: ####
- A blank (vanilla install) RHEL 7 server (target server). You will run the setup commands here.
Expand All @@ -22,18 +23,30 @@ Throughout this documentation, ensure that you understand the following terminol

On the target server:

1. git clone this project.
1. Clone this repository with git:
```console
# git clone https://github.com/RedHatSatellite/satellite-clone.git
# yum install git
# git clone https://github.com/RedHatSatellite/satellite-clone.git
```
2. Enable the Ansible repository corresponding to your Satellite version
|Satellite Version|Ansible Repository |
|-----------------|------------------------------|
|6.9 |rhel-7-server-ansible-2.9-rpms|
|6.8 |rhel-7-server-ansible-2.9-rpms|
|6.7 |rhel-7-server-ansible-2.8-rpms|
|6.6 |rhel-7-server-ansible-2.8-rpms|
|6.5 |rhel-7-server-ansible-2.6-rpms|

2. Install `ansible` package. Ansible should be installed from extras channel.
```console
# subscription-manager repos --enable rhel-7-server-extras-rpms
# yum install -y ansible
# subscription-manager repos --enable REPO_NAME
```

Now you can proceed to performing the [cloning process](docs/satellite-clone.md). Please check our [FAQ section](docs/faqs.md) for frequently asked questions.
3. Install the `ansible` package:
```console
# yum install ansible
```

Proceed to performing the [cloning process](docs/satellite-clone.md). Please check our [FAQ section](docs/faqs.md) for frequently asked questions.

## Development ##

Expand Down
2 changes: 1 addition & 1 deletion library/parse_backup_metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
# - Full path (including file name) to metadata.yml
# required: true

SUPPORTED_VERSIONS = ["6.5", "6.6", "6.7", "6.8"]
SUPPORTED_VERSIONS = ["6.5", "6.6", "6.7", "6.8", "6.9"]

def find_rpm(rpms, pattern):
matches = [r for r in rpms if pattern.match(r)]
Expand Down
1 change: 1 addition & 0 deletions roles/satellite-clone/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,4 @@ overwrite_etc_hosts: True
check_networking_interfaces: True
sp_features_table_name: smart_proxy_features
selinux_packages: []
ansible_repository_label: "rhel-7-server-ansible-{{ satellite_ansible_version }}-rpms"
11 changes: 7 additions & 4 deletions roles/satellite-clone/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
when: enable_repos and disable_repos_result_fail

- name: Enable required repos for Satellite installation
command: subscription-manager repos --enable rhel-{{ ansible_distribution_major_version }}-server-rpms --enable rhel-server-rhscl-{{ ansible_distribution_major_version }}-rpms --enable rhel-{{ ansible_distribution_major_version }}-server-satellite-{{ satellite_version }}-rpms --enable rhel-7-server-satellite-maintenance-6-rpms
command: subscription-manager repos --enable rhel-{{ ansible_distribution_major_version }}-server-rpms --enable rhel-server-rhscl-{{ ansible_distribution_major_version }}-rpms --enable rhel-{{ ansible_distribution_major_version }}-server-satellite-{{ satellite_version }}-rpms --enable rhel-7-server-satellite-maintenance-6-rpms --enable {{ ansible_repository_label }}
ignore_errors: True
register: enable_repos_result
when: enable_repos
Expand Down Expand Up @@ -182,7 +182,7 @@
file:
path: /var/opt/rh/rh-postgresql12/lib/pgsql/data/postgresql.conf
state: absent
when: satellite_version in ["6.8"]
when: satellite_version in ["6.8", "6.9"]

- name: Restore selinux context on the filesystem
command: restorecon -R /
Expand All @@ -192,8 +192,11 @@
# candlepin is already set up. We remove it so candlepin is set up correctly.
- name: Remove cpdb_done file
file:
path: /var/lib/candlepin/cpdb_done
path: "{{ item }}"
state: absent
with_items:
- /var/lib/candlepin/cpdb_done
- /var/lib/candlepin/.puppet-candlepin-cpdb-create-done

# jmx.conf can cause issues when re-running the installer later in the playbook
- name: Remove jmx.conf file
Expand Down Expand Up @@ -265,7 +268,7 @@
line: "---\n:foreman:\n :username: admin\n :password: changeme"

- name: Run installer upgrade to match latest z-version
command: 'satellite-installer --upgrade {{ satellite_upgrade_options | default("") }}'
command: 'satellite-installer {{ satellite_upgrade_options | default("") }}'
environment:
HOSTNAME: "{{ hostname }}"

Expand Down
3 changes: 2 additions & 1 deletion roles/satellite-clone/vars/satellite_6.5.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ satellite_installer_cmd: satellite-installer
satellite_scenario: satellite
capsule_puppet_module: foreman-proxy
satellite_installer_options: "--foreman-ipa-authentication false --reset-puppet-server-ssl-chain-filepath --disable-system-checks"
satellite_upgrade_options: "--disable-system-checks"
satellite_upgrade_options: "--upgrade --disable-system-checks"
verify_rake_task: reimport
sp_features_table_name: features_smart_proxies
db_packages:
- postgresql-server
- rh-mongodb34-syspaths
satellite_ansible_version: '2.6'
3 changes: 2 additions & 1 deletion roles/satellite-clone/vars/satellite_6.6.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ satellite_installer_cmd: satellite-installer
satellite_scenario: satellite
capsule_puppet_module: foreman-proxy
satellite_installer_options: "--foreman-ipa-authentication false --reset-puppet-server-ssl-chain-filepath --disable-system-checks"
satellite_upgrade_options: "--disable-system-checks"
satellite_upgrade_options: "--upgrade --disable-system-checks"
verify_rake_task: reimport
db_packages:
- postgresql-server
- rh-mongodb34-syspaths
satellite_ansible_version: '2.8'
3 changes: 2 additions & 1 deletion roles/satellite-clone/vars/satellite_6.7.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ satellite_installer_cmd: satellite-installer
satellite_scenario: satellite
capsule_puppet_module: foreman-proxy
satellite_installer_options: "--foreman-ipa-authentication false --reset-puppet-server-ssl-chain-filepath --disable-system-checks"
satellite_upgrade_options: "--disable-system-checks"
satellite_upgrade_options: "--upgrade --disable-system-checks"
verify_rake_task: reimport
db_packages:
- postgresql-server
- rh-mongodb34-syspaths
satellite_ansible_version: '2.8'
1 change: 1 addition & 0 deletions roles/satellite-clone/vars/satellite_6.8.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ db_packages:
- rh-mongodb34-syspaths
- rh-postgresql12-syspaths
- rh-postgresql12-postgresql-evr
satellite_ansible_version: '2.9'
22 changes: 22 additions & 0 deletions roles/satellite-clone/vars/satellite_6.9.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
satellite_package: satellite
satellite_installer_cmd: satellite-installer
satellite_scenario: satellite
capsule_puppet_module: foreman-proxy

# See the following issues for installer options
# https://github.com/RedHatSatellite/satellite-clone/issues/268
# https://github.com/RedHatSatellite/satellite-clone/issues/349
satellite_installer_options: "--foreman-ipa-authentication false --reset-puppet-server-ssl-chain-filepath --disable-system-checks"
satellite_upgrade_options: "--disable-system-checks"
verify_rake_task: reimport
selinux_packages:
- crane-selinux
- foreman-selinux
- katello-selinux
- pulpcore-selinux
db_packages:
- rh-mongodb34-syspaths
- rh-postgresql12-syspaths
- rh-postgresql12-postgresql-evr
satellite_ansible_version: '2.9'

0 comments on commit 0fd2377

Please sign in to comment.