ico-analyzer

command module
v0.0.0-...-1e18c51 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 14, 2019 License: GPL-3.0 Imports: 26 Imported by: 0

README

ICO Analyzer

Prerequisites for testing Lambda function locally

  • Docker
  • AWS SAM CLI

The account that you are running the commands with should be able to manager Docker (e.g., be member of the docker group or use sudo)

Install AWS SAM CLI

To install AWS SAM CLI, run the following command:

pip install --upgrade aws-sam-cli

For more details please go to https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/serverless-sam-cli-install.html

Build locally

To build the code locally please use the following command:

CI_PIPELINE_ID=local build/linux-build.sh

Test locally

Please build the code as explained in the previous section. After the code is built, run the following command to start the local API Gateway instance:

sam local start-api

After the API Gateway container is up and running you, can call the Lambda function using http://127.0.0.1:3000/

For more details on testing and debugging the Lambda function locally, please check https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/serverless-sam-cli-using-debugging-golang.html

Examples

When the API Gateway is up and running, you can use the following commands to check if its working:

curl --request GET \
  --url http://127.0.0.1:3000/ 
curl --request POST \
  --url http://127.0.0.1:3000/ \
  --header 'Content-Type: application/json' \
  --data '{"name": "YourName"}'

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL