File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 5656ShareRef = Union [resources .Share , resources .RemovedShare ]
5757
5858_DOMAIN = 'domain'
59+ _CLUSTERED = 'clustered'
5960log = logging .getLogger (__name__ )
6061
6162
@@ -1122,12 +1123,15 @@ def _generate_config(
11221123 for share in shares
11231124 }
11241125
1126+ instance_features = []
1127+ if cluster .is_clustered ():
1128+ instance_features .append ('ctdb' )
11251129 cfg : Dict [str , Any ] = {
11261130 'samba-container-config' : 'v0' ,
11271131 'configs' : {
11281132 cluster .cluster_id : {
11291133 'instance_name' : cluster .cluster_id ,
1130- 'instance_features' : [] ,
1134+ 'instance_features' : instance_features ,
11311135 'globals' : ['default' , cluster .cluster_id ],
11321136 'shares' : list (share_configs .keys ()),
11331137 },
@@ -1168,6 +1172,8 @@ def _generate_smb_service_spec(
11681172 features = []
11691173 if cluster .auth_mode == AuthMode .ACTIVE_DIRECTORY :
11701174 features .append (_DOMAIN )
1175+ if cluster .is_clustered ():
1176+ features .append (_CLUSTERED )
11711177 # only one config uri can be used, the input list should be
11721178 # ordered from lowest to highest priority and the highest priority
11731179 # item that exists in the store will be used.
You can’t perform that action at this time.
0 commit comments