Skip to content

Commit

Permalink
Split edpm into nodeset and deployment stages
Browse files Browse the repository at this point in the history
Signed-off-by: Fabricio Aguiar <[email protected]>
  • Loading branch information
fao89 authored and abays committed Apr 25, 2024
1 parent 86fd5f3 commit eca1996
Show file tree
Hide file tree
Showing 29 changed files with 220 additions and 81 deletions.
46 changes: 34 additions & 12 deletions automation/vars/default.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,27 @@ vas:
src_file: nncp/values.yaml
build_output: ../control-plane.yaml

- path: examples/va/hci/edpm-pre-ceph
- path: examples/va/hci/edpm-pre-ceph/nodeset
wait_conditions:
- >-
oc -n openstack wait
osdpd edpm-deployment-pre-ceph --for condition=Ready
osdpns openstack-edpm --for condition=SetupReady
--timeout=600s
values:
- name: edpm-nodeset-values
src_file: values.yaml
build_output: nodeset-pre-ceph.yaml

- path: examples/va/hci/edpm-pre-ceph/deployment
wait_conditions:
- >-
oc -n openstack wait
osdpns openstack-edpm --for condition=Ready
--timeout=1500s
values:
- name: edpm-values
- name: edpm-deployment-values
src_file: values.yaml
build_output: dataplane-pre-ceph.yaml
build_output: deployment-pre-ceph.yaml
post_stage_run:
- name: Deploy Ceph
type: playbook
Expand All @@ -44,14 +55,25 @@ vas:
wait_conditions:
- >-
oc -n openstack wait
osdpd edpm-deployment-post-ceph --for condition=Ready
--timeout=40m
osdpns openstack-edpm --for condition=SetupReady
--timeout=10m
values:
- name: service-values
src_file: service-values.yaml
- name: edpm-values-post-ceph
- name: edpm-nodeset-values-post-ceph
src_file: values.yaml
build_output: nodeset-post-ceph.yaml

- path: examples/va/hci/deployment
wait_conditions:
- >-
oc -n openstack wait
osdpns openstack-edpm --for condition=Ready
--timeout=40m
values:
- name: edpm-deployment-values-post-ceph
src_file: values.yaml
build_output: dataplane-post-ceph.yaml
build_output: deployment-post-ceph.yaml

sriov:
stages:
Expand Down Expand Up @@ -85,7 +107,7 @@ vas:
oc -n openstack wait
osdpd edpm-deployment --for condition=Ready --timeout=1200s
values:
- name: edpm-values
- name: edpm-nodeset-values
src_file: values.yaml
build_output: dataplane.yaml

Expand Down Expand Up @@ -121,7 +143,7 @@ vas:
oc -n openstack wait
osdpd edpm-deployment --for condition=Ready --timeout=1200s
values:
- name: edpm-values
- name: edpm-nodeset-values
src_file: values.yaml
build_output: dataplane.yaml

Expand Down Expand Up @@ -157,7 +179,7 @@ vas:
oc -n openstack wait
osdpd edpm-deployment --for condition=Ready --timeout=1200s
values:
- name: edpm-values
- name: edpm-nodeset-values
src_file: values.yaml
build_output: dataplane.yaml

Expand Down Expand Up @@ -199,6 +221,6 @@ vas:
--for condition=Ready
--timeout=1200s
values:
- name: edpm-values
- name: edpm-nodeset-values
src_file: values.yaml
build_output: edpm.yaml
4 changes: 2 additions & 2 deletions automation/vars/uni01alpha.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ vas:
--for condition=Ready
--timeout=2400s
values:
- name: edpm-values
- name: edpm-nodeset-values
src_file: values.yaml
build_output: edpm-networker.yaml

Expand All @@ -58,6 +58,6 @@ vas:
--for condition=Ready
--timeout=2400s
values:
- name: edpm-values
- name: edpm-nodeset-values
src_file: values.yaml
build_output: edpm.yaml
2 changes: 1 addition & 1 deletion examples/dt/uni01alpha/networker/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: edpm-values
name: edpm-nodeset-values
annotations:
config.kubernetes.io/local-config: "true"

Expand Down
2 changes: 1 addition & 1 deletion examples/dt/uni01alpha/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: v1
kind: ConfigMap

metadata:
name: edpm-values
name: edpm-nodeset-values
annotations:
config.kubernetes.io/local-config: "true"

Expand Down
2 changes: 1 addition & 1 deletion examples/dt/uni06zeta/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: v1
kind: ConfigMap

metadata:
name: edpm-values
name: edpm-nodeset-values
annotations:
config.kubernetes.io/local-config: "true"

Expand Down
22 changes: 18 additions & 4 deletions examples/va/hci/dataplane-post-ceph.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,20 +14,34 @@ Change to the hci directory
```
cd architecture/examples/va/hci
```
Edit the [values.yaml](values.yaml) and [service-values.yaml](service-values.yaml)
Edit the [values.yaml](values.yaml) and [service-values.yaml](service-values.yaml)
files to suit your environment.
```
vi values.yaml
vi service-values.yaml
```
Generate the post-Ceph dataplane CRs.
Generate the post-Ceph dataplane nodeset CR.
```
kustomize build > dataplane-post-ceph.yaml
kustomize build > nodeset-post-ceph.yaml
```
Generate the post-Ceph dataplane deployment CR.
```
kustomize build deployment > deployment-post-ceph.yaml
```

## Create post-Ceph CRs

Create the nodeset CR
```
oc apply -f nodeset-post-ceph.yaml
```
Wait for post-Ceph dataplane nodeset setup to finish
```
oc wait osdpns openstack-edpm --for condition=SetupReady --timeout=600s
```
Create the deployment CR
```
oc apply -f dataplane-post-ceph.yaml
oc apply -f deployment-post-ceph.yaml
```

Wait for control plane to be available after updating
Expand Down
25 changes: 20 additions & 5 deletions examples/va/hci/dataplane-pre-ceph.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,19 +14,34 @@ Change to the hci directory
```
cd architecture/examples/va/hci
```
Edit the [edpm-pre-ceph/values.yaml](edpm-pre-ceph/values.yaml) file to suit
Edit the [edpm-pre-ceph/nodeset/values.yaml](edpm-pre-ceph/nodeset/values.yaml) file to suit
your environment.
```
vi edpm-pre-ceph/values.yaml
vi edpm-pre-ceph/nodeset/values.yaml
```
Generate the pre-Ceph dataplane CRs.
Generate the pre-Ceph dataplane nodeset CR.
```
kustomize build edpm-pre-ceph > dataplane-pre-ceph.yaml
kustomize build edpm-pre-ceph/nodeset > dataplane-nodeset-pre-ceph.yaml
```
Generate the pre-Ceph dataplane deployment CR.
```
kustomize build edpm-pre-ceph/deployment > dataplane-deployment-pre-ceph.yaml
```

## Create pre-Ceph CRs

Create the nodeset CR
```
oc apply -f dataplane-nodeset-pre-ceph.yaml
```
Wait for pre-Ceph dataplane nodeset setup to finish
```
oc wait osdpns openstack-edpm --for condition=SetupReady --timeout=600s
```

Start the deployment
```
oc apply -f dataplane-pre-ceph.yaml
oc apply -f dataplane-deployment-pre-ceph.yaml
```

Wait for pre-Ceph dataplane deployment to finish
Expand Down
13 changes: 13 additions & 0 deletions examples/va/hci/deployment/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# This is the kustomization for the FINAL step, edpm-post-ceph
---
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

components:
- ../../../../va/hci/edpm-post-ceph/deployment
# - https://github.com/openstack-k8s-operators/architecture/va/hci/edpm-post-ceph/?ref=main
## It's possible to replace ../../../va/hci/edpm-post-ceph/ with a git checkout URL as per:
## https://github.com/kubernetes-sigs/kustomize/blob/master/examples/remoteBuild.md

resources:
- values.yaml
11 changes: 11 additions & 0 deletions examples/va/hci/deployment/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# local-config: referenced, but not emitted by kustomize
---
apiVersion: v1
kind: ConfigMap
metadata:
name: edpm-deployment-values-post-ceph
annotations:
config.kubernetes.io/local-config: "true"
data:
deployment:
name: edpm-deployment-post-ceph
12 changes: 12 additions & 0 deletions examples/va/hci/edpm-pre-ceph/deployment/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

components:
- ../../../../../va/hci/edpm-pre-ceph/deployment
# - https://github.com/openstack-k8s-operators/architecture/va/hci/edpm-pre-ceph/?ref=main
## It's possible to replace ../../../../va/hci/edpm-pre-ceph/ with a git checkout URL as per:
## https://github.com/kubernetes-sigs/kustomize/blob/master/examples/remoteBuild.md

resources:
- values.yaml
12 changes: 12 additions & 0 deletions examples/va/hci/edpm-pre-ceph/deployment/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# yamllint disable rule:line-length
# local-config: referenced, but not emitted by kustomize
---
apiVersion: v1
kind: ConfigMap
metadata:
name: edpm-deployment-values
annotations:
config.kubernetes.io/local-config: "true"
data:
deployment:
name: edpm-deployment-pre-ceph
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

components:
- ../../../../va/hci/edpm-pre-ceph/
- ../../../../../va/hci/edpm-pre-ceph/nodeset
# - https://github.com/openstack-k8s-operators/architecture/va/hci/edpm-pre-ceph/?ref=main
## It's possible to replace ../../../../va/hci/edpm-pre-ceph/ with a git checkout URL as per:
## https://github.com/kubernetes-sigs/kustomize/blob/master/examples/remoteBuild.md
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,10 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: edpm-values
name: edpm-nodeset-values
annotations:
config.kubernetes.io/local-config: "true"
data:
deployment:
name: edpm-deployment-pre-ceph
ssh_keys:
# Authorized keys that will have access to the dataplane computes via SSH
authorized: CHANGEME
Expand Down
4 changes: 2 additions & 2 deletions examples/va/hci/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

components:
- ../../../va/hci/edpm-post-ceph/
- ../../../va/hci/edpm-post-ceph/nodeset
# - https://github.com/openstack-k8s-operators/architecture/va/hci/edpm-post-ceph/?ref=main
## It's possible to replace ../../../va/hci/edpm-post-ceph/ with a git checkout URL as per:
## https://github.com/kubernetes-sigs/kustomize/blob/master/examples/remoteBuild.md

resources:
- control-plane/nncp/values.yaml
- edpm-pre-ceph/values.yaml
- edpm-pre-ceph/nodeset/values.yaml
- service-values.yaml
- values.yaml
4 changes: 1 addition & 3 deletions examples/va/hci/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,10 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: edpm-values-post-ceph
name: edpm-nodeset-values-post-ceph
annotations:
config.kubernetes.io/local-config: "true"
data:
deployment:
name: edpm-deployment-post-ceph
nodeset:
services:
- install-certs
Expand Down
2 changes: 1 addition & 1 deletion examples/va/nfv/ovs-dpdk-sriov/edpm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: edpm-values
name: edpm-nodeset-values
annotations:
config.kubernetes.io/local-config: "true"
data:
Expand Down
2 changes: 1 addition & 1 deletion examples/va/nfv/ovs-dpdk/edpm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: edpm-values
name: edpm-nodeset-values
annotations:
config.kubernetes.io/local-config: "true"
data:
Expand Down
2 changes: 1 addition & 1 deletion examples/va/nfv/sriov/edpm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: edpm-values
name: edpm-nodeset-values
annotations:
config.kubernetes.io/local-config: "true"
data:
Expand Down
Loading

0 comments on commit eca1996

Please sign in to comment.