A developer is configuring a machine learning pipeline in Amazon SageMaker. The pipeline needs to retrieve a personal access token (PAT) to pull training code from a private Git repository. This PAT must be rotated monthly and accessed by pipelines running across multiple AWS accounts in the same organization. Additionally, the pipeline needs to retrieve non-sensitive training hyperparameters (such as learning rate and batch size) that are only used within the local AWS account. How should the developer store these values to meet the requirements securely and cost-effectively?
- Store the private Git repository token in AWS Secrets Manager and attach a resource-based policy to the secret to allow cross-account access. Store the hyperparameters as String parameters in AWS Systems Manager Parameter Store.Cevap
- BStore the private Git repository token as a SecureString parameter in AWS Systems Manager Parameter Store and attach a resource-based policy to the parameter to allow cross-account access. Store the hyperparameters in AWS Secrets Manager.
- CHardcode the private Git repository token directly in the SageMaker pipeline's script, and store the hyperparameters as String parameters in AWS Systems Manager Parameter Store.
- DStore both the private Git repository token and the hyperparameters in AWS Secrets Manager, enabling automatic rotation for both to centralize secret management.
Cevap
Store the private Git repository token in AWS Secrets Manager and attach a resource-based policy to the secret to allow cross-account access. Store the hyperparameters as String parameters in AWS Systems Manager Parameter Store.
The correct answer correctly identifies that AWS Secrets Manager should be used for the private Git repository token because it natively supports resource-based policies for cross-account sharing and automatic rotation. It also correctly identifies that Systems Manager Parameter Store is the most cost-effective service for storing non-sensitive hyperparameters, avoiding unnecessary Secrets Manager costs.
Adım Adım Çözüm
Anahtar Kavram
Choosing between AWS Secrets Manager and Systems Manager Parameter Store based on rotation, cross-account access, and cost-efficiency.
Tahmini Süre:1m 30s