From 7ad9f77dfdcbaba9553d96ae5fa25e7ba3ca5690 Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Sun, 20 Dec 2020 23:58:40 +0900 Subject: [PATCH] Do not set default values for the required parameters ... to raise appropriate errors if the required parameters are not set. Change-Id: If986f2c2227fe43ea9e506153055ea80c44c2017 --- manifests/service_instance.pp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/manifests/service_instance.pp b/manifests/service_instance.pp index 1e4aa5ec..693f5337 100644 --- a/manifests/service_instance.pp +++ b/manifests/service_instance.pp @@ -2,6 +2,12 @@ # # ===Parameters # +# [*service_instance_user*] +# (required) User in service instance. +# +# [*service_instance_password*] +# (required) Password to service instance user. +# # [*create_service_image*] # (optional) Upload the service image to glance. # Defaults to: true @@ -12,19 +18,13 @@ # Defaults to: 'manila-service-image' # # [*service_image_location*] -# (required) URL or pathname to the service image. This will be -# loaded into Glance. +# (optional) URL or pathname to the service image. This will be +# loaded into Glance. This is required when create_service_image is true. # # [*service_instance_name_template*] # (optional) Name of service instance. # Defaults to: 'manila_service_instance_%s' # -# [*service_instance_user*] -# (required) User in service instance. -# -# [*service_instance_password*] -# (required) Password to service instance user. -# # [*manila_service_keypair_name*] # (optional) Name of keypair that will be created and used # for service instance. @@ -76,12 +76,12 @@ # Defaults to: false # define manila::service_instance ( + $service_instance_user, + $service_instance_password, $create_service_image = true, $service_image_name = 'manila-service-image', $service_image_location = undef, $service_instance_name_template = 'manila_service_instance_%s', - $service_instance_user = undef, - $service_instance_password = undef, $manila_service_keypair_name = 'manila-service', $path_to_public_key = '~/.ssh/id_rsa.pub', $path_to_private_key = '~/.ssh/id_rsa',