Fix failure of gpg key creation in case of empty RequesterEmail
Change-Id: I68b77848ee692757a805efc0b4c6fe056747df67
diff --git a/generate-cookiecutter-products.groovy b/generate-cookiecutter-products.groovy
index c56f1a1..9df7611 100644
--- a/generate-cookiecutter-products.groovy
+++ b/generate-cookiecutter-products.groovy
@@ -137,7 +137,7 @@
withEnv(["GNUPGHOME=${env.WORKSPACE}/gpghome"]) {
if (context['secrets_encryption_enabled'] == 'True') {
sh "mkdir gpghome; chmod 700 gpghome"
- def secretKeyID = RequesterEmail
+ def secretKeyID = RequesterEmail ?: "salt@${context['cluster_domain']}".toString()
if (!context.get('secrets_encryption_private_key')) {
def batchData = """
Key-Type: 1