Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

Commit

Permalink
Merge pull request #3187 from hashicorp/kevin/lambda-function-url
Browse files Browse the repository at this point in the history
feat(aws-lambda): add URL releaser component
  • Loading branch information
Evan Phoenix authored May 6, 2022
2 parents 589edab + a7ec5d8 commit 56fa792
Show file tree
Hide file tree
Showing 19 changed files with 1,052 additions and 30 deletions.
3 changes: 3 additions & 0 deletions .changelog/3187.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:feature
plugin/lambda-function-url: Adds a new plugin and `releaser` component. This leverages Lambda URLs.
```
12 changes: 12 additions & 0 deletions builtin/aws/lambda/function_url/plugin.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package function_url

import (
sdk "github.com/hashicorp/waypoint-plugin-sdk"
)

//go:generate protoc -I ../../../../.. -I ../../../../thirdparty/proto --go_out=../../../../.. waypoint/builtin/aws/lambda/function_url/plugin.proto

// Options are the SDK options to use for instantiation for the plugin.
var Options = []sdk.Option{
sdk.WithComponents(&Releaser{}),
}
309 changes: 309 additions & 0 deletions builtin/aws/lambda/function_url/plugin.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

30 changes: 30 additions & 0 deletions builtin/aws/lambda/function_url/plugin.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
syntax = "proto3";

package function_url;

option go_package = "waypoint/builtin/aws/lambda/function_url";

import "opaqueany/any.proto";

message Release {
// The function's public url
string url = 1;

// The AWS region the function is deployed in
string region = 2;

// The ARN for the Lambda function itself.
string func_arn = 3;

// The ARN for the version of the Lambda function this deployment uses.
string ver_arn = 4;

opaqueany.Any resource_state = 5;
}

// Resource contains the internal resource states.
message Resource {
message FunctionUrl {
string url = 1;
}
}
7 changes: 7 additions & 0 deletions builtin/aws/lambda/function_url/release.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
package function_url

import "github.com/hashicorp/waypoint-plugin-sdk/component"

func (r *Release) URL() string { return r.Url }

var _ component.Release = (*Release)(nil)
Loading

0 comments on commit 56fa792

Please sign in to comment.