Skip to content

Commit

Permalink
chore: improve
Browse files Browse the repository at this point in the history
  • Loading branch information
StarpTech committed Jan 20, 2024
1 parent 10ef1e8 commit 85e4b62
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 4 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/aws-router-binary-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,10 @@ jobs:
goarch: ${{ matrix.goarch }}
# Where to run `go build .`
project_path: "aws-lambda-router/cmd"
binary_name: "aws-lambda-router"
# Convention from AWS Lambda
binary_name: "bootstrap"
pre_command: export CGO_ENABLED=0
build_flags: -trimpath
# AWS lambda only support zip files
compress_assets: zip
ldflags: -extldflags -static -X module github.com/wundergraph/cosmo/aws-lambda-router/internal.Version=${{ steps.split.outputs._1 }}
overwrite: true
extra_files: LICENSE
Expand Down
14 changes: 13 additions & 1 deletion aws-lambda-router/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,4 +70,16 @@ make deploy
```

The command will package and deploy your application to AWS.
You can find your API Gateway Endpoint URL in the output values displayed after deployment.
You can find your API Gateway Endpoint URL in the output values displayed after deployment.

# User Guide

1. Download the Lambda Router binary from the official [Router Releases](https://github.com/wundergraph/cosmo/releases?q=aws-lambda-router&expanded=true) page.
2. Create a .zip archive with the binary and the `router.json` file. You can download the latest `router.json` with [`wgc federated-graph fetch`](https://cosmo-docs.wundergraph.com/cli/federated-graph/fetch).
```
.
└── myFunction.zip/
├── bootstrap
└── config.json
```
3. Deploy the .zip archive to AWS Lambda. You can use AWS cli or the AWS console. Alternatively, you can use your IaC tool of choice.

0 comments on commit 85e4b62

Please sign in to comment.