{"id":16056160,"url":"https://github.com/ryichk/go-echo-lambda-function-url-template","last_synced_at":"2025-10-07T23:18:03.385Z","repository":{"id":254571602,"uuid":"846886025","full_name":"ryichk/go-echo-lambda-function-url-template","owner":"ryichk","description":"Template for publishing Go's Echo Web app with Lambda Function URL using Lambda Web Adapter.","archived":false,"fork":false,"pushed_at":"2024-12-12T00:03:28.000Z","size":12,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-12T22:44:18.236Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ryichk.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-24T08:19:46.000Z","updated_at":"2024-08-24T11:49:26.000Z","dependencies_parsed_at":"2024-08-24T12:46:53.305Z","dependency_job_id":"516fb120-8463-4cfc-b8d3-110e96920952","html_url":"https://github.com/ryichk/go-echo-lambda-function-url-template","commit_stats":null,"previous_names":["ryichk/go-echo-lambda-function-url-template"],"tags_count":1,"template":true,"template_full_name":null,"purl":"pkg:github/ryichk/go-echo-lambda-function-url-template","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryichk%2Fgo-echo-lambda-function-url-template","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryichk%2Fgo-echo-lambda-function-url-template/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryichk%2Fgo-echo-lambda-function-url-template/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryichk%2Fgo-echo-lambda-function-url-template/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ryichk","download_url":"https://codeload.github.com/ryichk/go-echo-lambda-function-url-template/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryichk%2Fgo-echo-lambda-function-url-template/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278861078,"owners_count":26058641,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-07T02:00:06.786Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-09T02:40:39.120Z","updated_at":"2025-10-07T23:18:03.355Z","avatar_url":"https://github.com/ryichk.png","language":"Go","readme":"# go-echo-lambda-function-url-template\n\nThis is a template for publishing Go's Echo Web app with Lambda Function URL using Lambda Web Adapter.\n\n## Requirements\n\n* AWS CLI already configured with Administrator permission\n* [Docker installed](https://www.docker.com/community-edition)\n* SAM CLI - [Install the SAM CLI](https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/serverless-sam-cli-install.html)\n\nYou may need the following for local testing.\n* [Golang](https://golang.org)\n\n## Setup process\n\n### Installing dependencies \u0026 building the target\n\nIn this example we use the built-in `sam build` to build a docker image from a Dockerfile and then copy the source of your application inside the Docker image.\nRead more about [SAM Build here](https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/sam-cli-command-reference-sam-build.html)\n\n### Local development\n\n```shell\ngo run app/main.go\n```\n\nIf the previous command ran successfully you should now be able to hit the following local endpoint to invoke your function `http://localhost:8000/`\n\n## Packaging and deployment\n\nAWS Lambda Golang runtime requires a flat folder with the executable generated on build step. SAM will use `CodeUri` property to know where to look up for the application:\n\n```yaml\n...\n    FirstFunction:\n        Type: AWS::Serverless::Function\n        Properties:\n            CodeUri: app/\n            ...\n```\n\nTo deploy your application for the first time, run the following in your shell:\n\n```shell\nsam deploy --guided\n```\n\nThe command will package and deploy your application to AWS, with a series of prompts:\n\n* **Stack Name**: The name of the stack to deploy to CloudFormation. This should be unique to your account and region, and a good starting point would be something matching your project name.\n* **AWS Region**: The AWS region you want to deploy your app to.\n* **Confirm changes before deploy**: If set to yes, any change sets will be shown to you before execution for manual review. If set to no, the AWS SAM CLI will automatically deploy application changes.\n* **Allow SAM CLI IAM role creation**: Many AWS SAM templates, including this example, create AWS IAM roles required for the AWS Lambda function(s) included to access AWS services. By default, these are scoped down to minimum required permissions. To deploy an AWS CloudFormation stack which creates or modifies IAM roles, the `CAPABILITY_IAM` value for `capabilities` must be provided. If permission isn't provided through this prompt, to deploy this example you must explicitly pass `--capabilities CAPABILITY_IAM` to the `sam deploy` command.\n* **Save arguments to samconfig.toml**: If set to yes, your choices will be saved to a configuration file inside the project, so that in the future you can just re-run `sam deploy` without parameters to deploy changes to your application.\n\nYou can find your API Gateway Endpoint URL in the output values displayed after deployment.\n\n### Testing\n\nWe use `testing` package that is built-in in Golang and you can simply run the following command to run our tests locally:\n\n```shell\ngo test ./app -v\n```\n\n## Appendix\n\n### Golang installation\n\nPlease ensure Go 1.x (where 'x' is the latest version) is installed as per the instructions on the official golang website: https://golang.org/doc/install\n\nA quickstart way would be to use Homebrew, chocolatey or your linux package manager.\n\n#### Homebrew (Mac)\n\nIssue the following command from the terminal:\n\n```shell\nbrew install golang\n```\n\nIf it's already installed, run the following command to ensure it's the latest version:\n\n```shell\nbrew update\nbrew upgrade golang\n```\n\n#### Chocolatey (Windows)\n\nIssue the following command from the powershell:\n\n```shell\nchoco install golang\n```\n\nIf it's already installed, run the following command to ensure it's the latest version:\n\n```shell\nchoco upgrade golang\n```\n\n## Bringing to the next level\n\nHere are a few ideas that you can use to get more acquainted as to how this overall process works:\n\n* Create an additional API resource (e.g. /hello/{proxy+}) and return the name requested through this new path\n* Update unit test to capture that\n* Package \u0026 Deploy\n\nNext, you can use the following resources to know more about beyond hello world samples and how others structure their Serverless applications:\n\n* [AWS Serverless Application Repository](https://aws.amazon.com/serverless/serverlessrepo/)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryichk%2Fgo-echo-lambda-function-url-template","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fryichk%2Fgo-echo-lambda-function-url-template","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryichk%2Fgo-echo-lambda-function-url-template/lists"}