Add Flannel deployment to deploy-env role

Change-Id: I72f3f29196ea1d433655c8862ac34718df18c7ea
This commit is contained in:
Vladimir Kozhukalov 2024-07-15 04:32:50 -05:00
parent 8077898106
commit 62f12e3a1f
10 changed files with 74 additions and 11 deletions

View File

@ -14,15 +14,19 @@ kube_version_repo: "v1.29"
# the list of k8s package versions are available here
# https://pkgs.k8s.io/core:/stable:/{{ kube_version_repo }}/deb/Packages
kube_version: "1.29.5-1.1"
calico_setup: true
calico_version: "v3.27.0"
calico_manifest_url: "https://raw.githubusercontent.com/projectcalico/calico/{{ calico_version }}/manifests/calico.yaml"
helm_version: "v3.6.3"
crictl_version: "v1.26.1"
calico_setup: true
calico_version: "v3.27.0"
calico_manifest_url: "https://raw.githubusercontent.com/projectcalico/calico/{{ calico_version }}/manifests/calico.yaml"
cilium_setup: false
cilium_version: "1.15.6"
flannel_setup: false
flannel_version: v0.25.4
kubectl:
user: zuul
group: zuul
@ -30,7 +34,7 @@ kubectl:
osh_plugin_repo: "https://opendev.org/openstack/openstack-helm-plugin.git"
kubeadm:
pod_network_cidr: "10.244.0.0/24"
pod_network_cidr: "10.244.0.0/16"
service_cidr: "10.96.0.0/16"
docker:
root_path: /var/lib/docker

View File

@ -45,7 +45,7 @@
register: ssh_public_key
when: (inventory_hostname in (groups['primary'] | default([])))
- name: Set primary wireguard public key
- name: Set primary ssh public key
set_fact:
client_ssh_public_key: "{{ (groups['primary'] | map('extract', hostvars, ['ssh_public_key', 'stdout']))[0] }}"
when: inventory_hostname in (groups['k8s_cluster'] | default([]))

View File

@ -0,0 +1,20 @@
---
- name: Add Flannel Helm repo
become: false
when: inventory_hostname in (groups['primary'] | default([]))
block:
- name: Add Flannel chart repo
kubernetes.core.helm_repository:
name: flannel
repo_url: "https://flannel-io.github.io/flannel/"
- name: Install Flannel
kubernetes.core.helm:
name: flannel
chart_ref: flannel/flannel
namespace: kube-flannel
create_namespace: true
chart_version: "{{ flannel_version }}"
release_values:
podCidr: "{{ kubeadm.pod_network_cidr }}"
...

View File

@ -48,7 +48,7 @@
file: k8s_client.yaml
when: inventory_hostname in (groups['primary'] | default([]))
- name: Include K8s Calico tasks
- name: Include Calico tasks
include_tasks:
file: calico.yaml
when: calico_setup
@ -58,6 +58,11 @@
file: cilium.yaml
when: cilium_setup
- name: Include Flannel tasks
include_tasks:
file: flannel.yaml
when: flannel_setup
- name: Include coredns resolver tasks
include_tasks:
file: coredns_resolver.yaml

View File

@ -13,7 +13,7 @@
---
ceph_osd_data_device: "/dev/loop0"
kubeadm:
pod_network_cidr: "10.244.0.0/24"
pod_network_cidr: "10.244.0.0/16"
osh_params:
container_distro_name: ubuntu
container_distro_version: focal

View File

@ -13,7 +13,7 @@
---
ceph_osd_data_device: "/dev/loop0"
kubeadm:
pod_network_cidr: "10.244.0.0/24"
pod_network_cidr: "10.244.0.0/16"
osh_params:
container_distro_name: ubuntu
container_distro_version: focal

View File

@ -15,7 +15,7 @@
set -xe
: ${CEPH_OSD_DATA_DEVICE:="/dev/loop100"}
: ${POD_NETWORK_CIDR:="10.244.0.0/24"}
: ${POD_NETWORK_CIDR:="10.244.0.0/16"}
: ${OSH_INFRA_HELM_REPO:="../openstack-helm-infra"}
: ${OSH_INFRA_PATH:="../openstack-helm-infra"}

View File

@ -15,7 +15,7 @@
set -xe
: ${CEPH_OSD_DATA_DEVICE:="/dev/loop100"}
: ${POD_NETWORK_CIDR:="10.244.0.0/24"}
: ${POD_NETWORK_CIDR:="10.244.0.0/16"}
: ${OSH_INFRA_HELM_REPO:="../openstack-helm-infra"}
: ${OSH_INFRA_PATH:="../openstack-helm-infra"}

View File

@ -93,7 +93,7 @@
containerd:
root_path: "/opt/ext_vol/containerd"
kubeadm:
pod_network_cidr: "10.244.0.0/24"
pod_network_cidr: "10.244.0.0/16"
service_cidr: "10.96.0.0/16"
osh_plugin_repo: "{{ zuul.project.src_dir }}/../openstack-helm-plugin"
loopback_setup: true
@ -299,6 +299,39 @@
- ./tools/deployment/common/memcached.sh
- ./tools/deployment/openstack/keystone.sh
- job:
name: openstack-helm-infra-keystone-flannel-2024-1-ubuntu_jammy
parent: openstack-helm-infra-deploy
nodeset: openstack-helm-3nodes-ubuntu_jammy
files:
- ^helm-toolkit/.*
- ^roles/.*
- ^rabbitmq/.*
- ^mariadb/.*
- ^memcached/.*
vars:
osh_params:
openstack_release: "2024.1"
container_distro_name: ubuntu
container_distro_version: jammy
calico_setup: false
flannel_setup: true
gate_scripts:
- ./tools/deployment/common/prepare-k8s.sh
- ./tools/deployment/common/prepare-charts.sh
- ./tools/deployment/common/ingress.sh
- ./tools/deployment/ceph/ceph-rook.sh
- ./tools/deployment/ceph/ceph-adapter-rook.sh
- ./tools/deployment/common/setup-client.sh
- |
export NAMESPACE=openstack
export OSH_INFRA_EXTRA_HELM_ARGS="--set pod.replicas.server=1 ${OSH_INFRA_EXTRA_HELM_ARGS}"
export RUN_HELM_TESTS=no
./tools/deployment/db/mariadb.sh
- ./tools/deployment/common/rabbitmq.sh
- ./tools/deployment/common/memcached.sh
- ./tools/deployment/openstack/keystone.sh
- job:
name: openstack-helm-infra-cinder-2023-1-ubuntu_focal
description: |

View File

@ -33,6 +33,7 @@
- openstack-helm-infra-tls-2024-1-ubuntu_jammy
- openstack-helm-infra-compute-kit-dpdk-2023-2-ubuntu_jammy
- openstack-helm-infra-keystone-cilium-2024-1-ubuntu_jammy
- openstack-helm-infra-keystone-flannel-2024-1-ubuntu_jammy
- openstack-helm-infra-ceph-migrate
gate:
jobs: