Skip to content

Commit bb98a19

Browse files
committed
feat: Add secret plugin to embedded membrane server.
1 parent 2f7926d commit bb98a19

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

pkg/cmd/run/root.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ import (
3131
"github.com/nitrictech/newcli/pkg/provider/run"
3232
"github.com/nitrictech/nitric/pkg/membrane"
3333
boltdb_service "github.com/nitrictech/nitric/pkg/plugins/document/boltdb"
34+
secret_service "github.com/nitrictech/nitric/pkg/plugins/secret/dev"
3435
minio "github.com/nitrictech/nitric/pkg/plugins/storage/minio"
3536
"github.com/nitrictech/nitric/pkg/worker"
3637
)
@@ -75,6 +76,11 @@ var runCmd = &cobra.Command{
7576
dp, err := boltdb_service.New()
7677
cobra.CheckErr(err)
7778

79+
// Connect secrets plugin
80+
os.Setenv("LOCAL_SECRET_DIR", "./.nitric/")
81+
secp, err := secret_service.New()
82+
cobra.CheckErr(err)
83+
7884
// Create a new Worker Pool
7985
// TODO: We may want to override GetWorker on the default ProcessPool
8086
// For now we'll use the default and expand from there
@@ -93,6 +99,7 @@ var runCmd = &cobra.Command{
9399
mem, err := membrane.New(&membrane.MembraneOptions{
94100
ServiceAddress: "0.0.0.0:50051",
95101
ChildCommand: []string{"echo", "running membrane 🚀"},
102+
SecretPlugin: secp,
96103
StoragePlugin: sp,
97104
DocumentPlugin: dp,
98105
GatewayPlugin: gw,

0 commit comments

Comments
 (0)