Sign inSign up

alexisno/aws-api-import

By alexisno

•Updated over 10 years ago

Lets you create or update Amazon API Gateway APIs from a Swagger or RAML API representation.

Image
1

519

alexisno/aws-api-import repository overview

⁠docker-aws-api-import

Use aws-api-import⁠ in a docker container. Lets you create or update Amazon API Gateway APIs from a Swagger or RAML API representation.

⁠Set AWS credentials and config

⁠Using environment variables

You can pass environment variables to the container to set AWS credentials and/or config.

docker run --rm \
  -e AWS_ACCESS_KEY_ID=******************** \
  -e AWS_SECRET_ACCESS_KEY=**************************************** \
  -e AWS_DEFAULT_REGION=us-east-1 \
  alexisno/aws-api-import <ARGS>

AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY have to be both specified to be effective.

⁠Using volumes

Alternatively, it is possible to inject AWS credentials and/or config in the container using volumes.

docker run --rm \
  -v ~/.aws/credentials:/root/.aws/credentials \
  -v ~/.aws/config:/root/.aws/config \
  alexisno/aws-api-import <ARGS>

See the default config file⁠.

⁠Execute aws-api-import

Inject the API representation file using a volume: -v `pwd`/path/to/swagger.json:/swagger.json.

docker run --rm \
  -e AWS_ACCESS_KEY_ID=******************** \
  -e AWS_SECRET_ACCESS_KEY=**************************************** \
  -e AWS_DEFAULT_REGION=us-east-1 \
  -v `pwd`/path/to/swagger.json:/swagger.json
  alexisno/aws-api-import <ARGS>

Use the arguments you would normally use with aws-api-import⁠. Don't forget to use the volume cited above to specify the path to the API representation file.

<ARGS> examples:

  • -c /swagger.json
  • --update <API_ID> --deploy <STAGE_NAME> /swagger.json

Tag summary

Content type

Image

Digest

sha256:0ac647505…

Size

290.6 MB

Last updated

over 10 years ago

docker pull alexisno/aws-api-import