# docker-aliyun-cli **Repository Path**: brunodelb/docker-aliyun-cli ## Basic Information - **Project Name**: docker-aliyun-cli - **Description**: Build Docker image for aliyun-cli for Alibaba Cloud Visit my blog about DevOps: http://www.devopstestlab.com - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2020-09-25 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # docker-aliyun-cli This repository provides the source files to create a Docker image to run Aliyun CLI commands. It embeds too the Serverless Framework and Node.js. ## Build To build the image: ``` docker build -t devopstestlab/aliyun-cli . ``` ## Usage To use this Docker image, you should follow two steps: - create the credentials file: ``` docker run -v $PWD/data:/root/.aliyun cli aliyun configure set --profile akProfile --mode AK --region eu-central-1 --access-key-id --access-key-secret ``` `` and `` are the credentials provided by Alibaba Cloud when you create an user with a programmatic access. A credentials file is created in the `./data/config.json` file. - execute aliyun-cli command by providing the credentials file: ``` docker run -v $PWD/data:/root/.aliyun:ro cli aliyun ecs DescribeRegions ``` It's a choice to store the credentials, with advantages and disadvantages. This way to do is very practical when you don't want to use interactive commands, for example for CI/CD.