hf-cloud-sagemaker-production-defaults
Pass
Audited by Gen Agent Trust Hub on Sep 10, 2026
Risk Level: SAFECOMMAND_EXECUTION
Full Analysis
- Interfacing with System Commands: The scripts
teardown.pyandinvoke_endpoint.pyutilizesubprocess.run()to interact with the AWS CLI for resource management and testing. This is a potential security consideration, as it involves executing external system commands. However, the implementation uses argument lists (rather than shell strings), which is a standard method to mitigate command injection risks. The skill also performs checks for the presence of the required CLI tools. - Model-Specific Execution Configuration: The deployment examples and documentation reference the environment variable
SM_VLLM_TRUST_REMOTE_CODE=true. This setting is frequently required for vLLM and Hugging Face model architectures to execute custom inference code. While this allows code execution from the model repository, it is a standard functional requirement for these deployment types. Users should ensure they deploy models only from trusted sources when this configuration is active. - AWS Resource Lifecycle Management: The skill includes a dedicated
teardown.pyutility that identifies and removes associated SageMaker resources (endpoints, models, configurations, alarms, and scaling targets). This facilitates proper resource lifecycle management and reduces the potential for orphaned resources or unnecessary costs. - Diagnostic Log Access: The
deploy_ic.pyscript includes functionality to scan CloudWatch logs for specific crash markers (e.g., "Worker died", "ImportError"). This provides diagnostic feedback during the deployment process by checking standard AWS log groups associated with the inference components.
Audit Metadata