Skip to content

Repository files navigation

go-lambda-template

This is a Cookiecutter template to create a Go AWS Lambda with Terraform deployment and infrastructure.

It is important to note that you should not try to git clone this project but use cookiecutter CLI instead as {{cookiecutter.project_slug}} will be rendered based on your input and therefore all variables and files will be rendered properly.

Requirements

Install cookiecutter command line:

Pip users:

  • pip install cookiecutter

Homebrew users:

  • brew install cookiecutter

Windows or Pipenv users:

  • pipenv install cookiecutter

NOTE: Pipenv is the new and recommended Python packaging tool that works across multiple platforms and makes Windows a first-class citizen.

Usage

Generate a new AWS Go Lambda: cookiecutter gh:flow-lab/go-lambda-template (or if you want to authenticate with ssh: cookiecutter git+ssh://git@github.com/flow-lab/go-lambda-template).

You'll be prompted a few questions to help this cookiecutter template to scaffold this project and after its completed you should see a new folder at your current path with the name of the project you gave as input.

After project has been generated, cd into it and push to github (make sure you have created the repository first):

$ cd <project-name>
$ git init .
$ git remote add origin git@github.com:<github-user>/<project-name>.git
$ git add . && git commit -m 'Initial commit' && git push origin master

NOTE: After you understand how cookiecutter works (cookiecutter.json, mainly), you can fork this repo and apply your own mechanisms to accelerate your development process and this can be followed for any programming language and OS.

Options

OptionDescription
project_nameProject name
project_slugProject slug
github_userThe GitHub user
project_short_descriptionThe project short description
lambda_nameLambda name
aws_regionThe aws region for deployment
terraform_state_s3The terraform state s3 bucket
terraform_versionThe terraform version

Credits

License

License: MIT

About

AWS Lambda GO template with Terraform deployment and infrastructure

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages