Plugin: Replacer based on AWS Secrets Manager and AWS Parameter Store

I want to load key-value pairs from AWS Secrets Manager and AWS Parameter Store. It should work the same way as env.X (environment variable replacers).

  client_id {aws.secrets.MY_APP_CLIENT_ID}
  scope {aws.parameters.MY_APP_OAUTH_SCOPES}

I imagine this would require a developing a plugin. What type of the plugin it would be? Is there an example of someone doing similar stuff?

1 Like

I think it would have to be an HTTP handler module for now, because we don’t have any plugin hooks for apps to add to the replacer.

But basically you just grab the replacer out of the context then set the stuff you want in it. Try to use the Map() for performance.

You could yoink the values out of an App though, i.e. preload the data into an app struct, then use ctx.App() to get it and fill the replacer.

1 Like

@francislavoie , thank you! It would be nice to have a plugin type for this.

And “yoink” is the technical term :smiley:

This topic was automatically closed after 30 days. New replies are no longer allowed.