Skip to content

AUFN-Ceph fixes and Rocky9 support #502

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
May 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 13 additions & 14 deletions doc/source/contributor/environments/aufn-ceph.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,18 @@ Setup

To begin the manual setup, access the baremetal node via SSH and install some basic dependencies.

CentOS:
CentOS or Rocky:

.. parsed-literal::

sudo dnf install -y gcc python3-dev python3-virtualenv
sudo dnf install -y gcc python3-devel

Ubuntu:

.. parsed-literal::

sudo apt update
sudo apt -y install gcc libffi-dev python3-dev python-is-python3 python3-virtualenv
sudo apt -y install gcc libffi-dev python3-dev python-is-python3


As a workaround for SMS lab's lack of DNS, add the following lines to ``/etc/hosts`` of the baremetal node:
Expand Down Expand Up @@ -82,7 +82,7 @@ Create a virtual environment and install Kayobe:
cd
mkdir -p venvs
pushd venvs
virtualenv kayobe
python3 -m venv kayobe
source kayobe/bin/activate
pip install -U pip
pip install ../src/kayobe
Expand All @@ -98,6 +98,7 @@ The following commands activate the correct kayobe environment and prepare the A

pushd ~/src/kayobe-config
source kayobe-env --environment aufn-ceph
$KAYOBE_CONFIG_PATH/environments/aufn-ceph/configure-local-networking.sh
kayobe control host bootstrap

Deployment
Expand All @@ -122,9 +123,9 @@ Once the local pulp server is deployed, we need to add the address of SMS lab te

.. parsed-literal::

SEED_IP=192.168.33.5
REMOTE_COMMAND="docker exec pulp sh -c 'echo $PULP_HOST | tee -a /etc/hosts'"
ssh stack@$SEED_IP $REMOTE_COMMAND
ssh stack@192.168.33.5
docker exec pulp sh -c 'echo "10.205.3.187 pulp-server pulp-server.internal.sms-cloud" | tee -a /etc/hosts'
exit

We can now sync the contents of the local pulp server with that of SMS test pulp and then complete the seed VM setup:

Expand Down Expand Up @@ -169,7 +170,7 @@ Finally, we create the bare minimum cloud infrastructure (networks, images, flav

.. parsed-literal::

$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-openstack.sh ~
$KAYOBE_CONFIG_PATH/environments/aufn-ceph/configure-openstack.sh ~

This completes the deployment process.

Expand All @@ -181,9 +182,8 @@ We can deploy a test VM to ensure that our 'universe' is up and running by first

.. parsed-literal::

VENV_DIR=~/openstack-env
python -m venv $VENV_DIR
source $VENV_DIR/bin/activate
python3 -m venv ~/openstack-env
source ~/openstack-env/bin/activate
pip install -U pip
pip install python-openstackclient

Expand All @@ -192,10 +192,9 @@ We then use the CLI to create a keypair, floating IP and test VM:
.. parsed-literal::

openstack keypair create --public-key ~/.ssh/id_rsa.pub mykey
openstack server create --key-name mykey --flavor m1.tiny \
--image cirros --network admin-tenant test-vm-1
openstack server create --key-name mykey --flavor m1.tiny --image cirros --network admin-tenant test-vm-1
openstack floating ip create external
openstack server add floating ip test-vm-1 `openstack floating ip list -c ID -f value`
openstack server list

which will create a VM named ``test-vm-1`` with a Cirros OS iamge and a default login password of 'gocubsgo'.
which will create a VM named ``test-vm-1`` with a Cirros OS image and a default login password of 'gocubsgo'.
2 changes: 2 additions & 0 deletions etc/kayobe/environments/aufn-ceph/compute.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
---
compute_bootstrap_user: "{{ 'cloud-user' if os_distribution == 'centos' else os_distribution }}"
2 changes: 2 additions & 0 deletions etc/kayobe/environments/aufn-ceph/controllers.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
---
controller_bootstrap_user: "{{ 'cloud-user' if os_distribution == 'centos' else os_distribution }}"
2 changes: 2 additions & 0 deletions etc/kayobe/environments/aufn-ceph/inventory/groups
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ storage-ceph
[rgws:children]
storage-ceph

[storage:children]
storage-ceph

###############################################################################
# Monitoring groups
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ download_ipa: true
use_cirros: true
{% if os_distribution == 'ubuntu' %}
cirros_deploy_image_upstream_url: "https://cloud-images.ubuntu.com/focal/current/focal-server-cloudimg-amd64.img"
{% elif os_distribution == 'rocky' and os_release == '9' %}
cirros_deploy_image_upstream_url: "https://dl.rockylinux.org/pub/rocky/9/images/x86_64/Rocky-9-GenericCloud.latest.x86_64.qcow2"
{% else %}
cirros_deploy_image_upstream_url: "https://cloud.centos.org/centos/8-stream/x86_64/images/CentOS-Stream-GenericCloud-8-20220913.0.x86_64.qcow2"
{% endif %}
2 changes: 2 additions & 0 deletions etc/kayobe/environments/aufn-ceph/seed.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
---
seed_bootstrap_user: "{{ 'cloud-user' if os_distribution == 'centos' else os_distribution }}"
1 change: 1 addition & 0 deletions etc/kayobe/environments/aufn-ceph/storage.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
---
storage_bootstrap_user: "{{ 'cloud-user' if os_distribution == 'centos' else os_distribution }}"

###############################################################################
# Storage node LVM configuration.
Expand Down