Configuring externalizing the sensitive values of privacera properties¶
The privacera_spark.properties file contains sensitive information required by the Spark plugin deployed in EMR Serverless. To avoid including this sensitive data in the Docker image, you can externalize the values from privacera_spark.properties by following these steps:
-
Set the following key in vars.emr-serverless.yml
YAML -
Run post-install
-
Create the docker image and push it to the ECR. Refer to the Create docker image section for more details.
-
Once your post install is done, you can find the values for the above properties as follows:
Property Value can be read from spark.hadoop.privacera.signer.base.url vi ~/privacera/privacera-manager/output/service-urls.txt
You can copy theEXTERNAL
URL underDATASERVER
spark.hadoop.privacera.signer.truststore.password vi ~/privacera/privacera-manager/config/custom-vars/vars.ssl.yml
You can copy the value set to the variableSSL_DEFAULT_PASSWORD
.
By default, the password is set aschangeit
.spark.hadoop.privacera.signer.truststore.type vi ~/privacera/privacera-manager/config/custom-vars/vars.ssl.yml
You can copy the value set to the variableSSL_SIGNED_CERT_FORMAT
.
By default, the format is set asPKCS12
.spark.hadoop.privacera.clusterName This is the name you have set for the EMR cluster. -
Edit the EMR serverless application and update below properties.
-
Update the EMR Serverless application configuration and add below Privacera-specific properties to the spark-defaults section.
JSON Creating an AWS Secrets Manager secret¶
- Go to AWS Secrets Manager.
- Choose Store a new secret.
- Under Choose secret type, choose Other type of secret.
- Click on the Plaintext tab, and paste the value of the privacera property.
- For Encryption key, select your AWS KMS key. Click Next.
- Provide a proper name for the secret.
- Add a description for the secret.
- Under Resource Permissions, click Edit permissions. Refer the below policy for the required permissions.
- Click Next.
- Click Next again to proceed through the default options.
- Review the details and click Store.
-
Save the application configuration. Now, you can start the EMR Serverless application.
- Prev topic: Advanced Configuration