blob: 8e51bfe377bf78a3dffa14881199db7ef3aa1f3c [file] [log] [blame]
Mohammed Naser547f21b2022-05-19 21:55:24 -04001# Copyright (c) 2022 VEXXHOST, Inc.
2#
3# Licensed under the Apache License, Version 2.0 (the "License"); you may
4# not use this file except in compliance with the License. You may obtain
5# a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12# License for the specific language governing permissions and limitations
13# under the License.
14
15- name: Deploy cluster
16 kubernetes.core.k8s:
17 state: present
18 definition:
19 apiVersion: rabbitmq.com/v1beta1
20 kind: RabbitmqCluster
21 metadata:
22 name: "rabbitmq-{{ rabbitmq_cluster_name }}"
23 namespace: openstack
24 spec:
25 affinity:
26 nodeAffinity:
27 requiredDuringSchedulingIgnoredDuringExecution:
28 nodeSelectorTerms:
29 - matchExpressions:
30 - key: openstack-control-plane
31 operator: In
32 values:
33 - enabled
okozachenkof2f87db2022-06-01 19:53:18 +100034 resources:
35 requests:
36 cpu: 500m
37 memory: 1Gi
38 limits:
39 cpu: "1"
40 memory: 2Gi
Mohammed Naser547f21b2022-05-19 21:55:24 -040041 wait: true
42 wait_timeout: 600
43 wait_condition:
44 type: ClusterAvailable
45 status: "True"
Mohammed Naserc8e1a452022-08-11 16:16:13 -040046 # NOTE(mnaser): Since we haven't moved to the operator pattern yet, we need to
47 # keep retrying a few times as the CRDs might not be installed
48 # yet.
49 retries: 60
50 delay: 5
51 register: _result
52 until: _result is not failed