19 # define PE_VARIANT__H
23 typedef struct clone_variant_data_s {
35 int masters_allocated;
39 gboolean applied_master_prefs;
40 gboolean merged_master_weights;
47 xmlNode *xml_obj_child;
49 gboolean notify_confirm;
51 } clone_variant_data_t;
53 # define get_clone_variant_data(data, rsc) \
54 CRM_ASSERT(rsc != NULL); \
55 CRM_ASSERT(rsc->variant == pe_clone || rsc->variant == pe_master); \
56 data = (clone_variant_data_t *)rsc->variant_opaque;
58 # elif VARIANT_CONTAINER
70 } container_grouping_t;
89 PE_CONTAINER_TYPE_UNKNOWN,
90 PE_CONTAINER_TYPE_DOCKER,
94 #define PE_CONTAINER_TYPE_UNKNOWN_S "unknown"
95 #define PE_CONTAINER_TYPE_DOCKER_S "Docker"
96 #define PE_CONTAINER_TYPE_RKT_S "rkt"
98 typedef struct container_variant_data_s {
101 int replicas_per_host;
108 char *docker_network;
109 char *ip_range_start;
110 char *docker_host_options;
111 char *docker_run_options;
112 char *docker_run_command;
113 const char *attribute_target;
121 enum container_type
type;
122 } container_variant_data_t;
124 # define get_container_variant_data(data, rsc) \
125 CRM_ASSERT(rsc != NULL); \
126 CRM_ASSERT(rsc->variant == pe_container); \
127 CRM_ASSERT(rsc->variant_opaque != NULL); \
128 data = (container_variant_data_t *)rsc->variant_opaque; \
132 typedef struct group_variant_data_s {
140 gboolean child_starting;
141 gboolean child_stopping;
143 } group_variant_data_t;
145 # define get_group_variant_data(data, rsc) \
146 CRM_ASSERT(rsc != NULL); \
147 CRM_ASSERT(rsc->variant == pe_group); \
148 CRM_ASSERT(rsc->variant_opaque != NULL); \
149 data = (group_variant_data_t *)rsc->variant_opaque; \
151 # elif VARIANT_NATIVE
153 typedef struct native_variant_data_s {
155 } native_variant_data_t;
157 # define get_native_variant_data(data, rsc) \
158 CRM_ASSERT(rsc != NULL); \
159 CRM_ASSERT(rsc->variant == pe_native); \
160 CRM_ASSERT(rsc->variant_opaque != NULL); \
161 data = (native_variant_data_t *)rsc->variant_opaque;
enum crm_ais_msg_types type