Skip to main content

About the Chef InSpec Alibaba Cloud resource pack

Chef InSpec has resources for auditing Alibaba.

You will need to install Alibaba Cloud SDK version 0.8.0 and require Alibaba Cloud credentials to use the Chef InSpec Alibaba Cloud resources.

Prerequisites

Before you begin you will need to:

Use the Alibaba Cloud resources

To use these resources in your controls, follow these steps:

  1. Define your Alibaba Cloud credentials in an envrc file or export them in your shell.

    # Example Alibaba Cloud Configuration
    export ALICLOUD_ACCESS_KEY="<ALICLOUD_ACCESS_KEY>"
    export ALICLOUD_SECRET_KEY="<ALICLOUD_SECRET_KEY>"
    export ALICLOUD_REGION="eu-west-1"
    
  2. Create a profile:

    inspec init profile --platform Alibaba Cloud <PROFILE_NAME>
    

    In the generated profile, inspec.yml defines the inspec/inspec-alicloud repository tar file as a dependency:

    name: <PROFILE_NAME>
    title: Ali Cloud InSpec Profile
    maintainer: The Authors
    copyright: The Authors
    copyright_email: you@example.com
    license: Apache-2.0
    summary: An InSpec Compliance Profile For Ali CLoud
    version: 0.1.0
    inspec_version: '~> 5'
    depends:
      - name: inspec-alicloud
        url: https://github.com/inspec/inspec-alicloud/archive/main.tar.gz
    supports:
      - platform: alicloud
    
  3. In the controls directory, add controls using the InSpec Alibaba Cloud resources listed below to audit your Alibaba Cloud resources.

  4. Run the profile:

    inspec exec <PROFILE_NAME> -t alicloud://
    

Alibaba Cloud resources

The following Chef InSpec Alibaba Cloud resources are available in this resource pack.

Thank you for your feedback!

×