Skip to content
This repository was archived by the owner on Dec 5, 2024. It is now read-only.

Support for External Credentials Provider #38

@dustindclark

Description

@dustindclark

This is a feature request. Looking for a clean way to inject an external credentials provider so that I don't have to store plain text credentials in SCM, environment variables, JVM startup params, etc. This is the only workaround that I've found, and obviously it's not a good one:

@CompileStatic
class BootStrap {
    SecretManagerService secretManagerService
    MailSender mailSender

    def init = { servletContext ->
        final Secret secret = secretManagerService.getSecret('my-secret-name')
        setMailPassword(secret)
    }

    @CompileDynamic
    void setMailPassword(final Secret secret) {
        //TODO: this is really bad.
        mailSender.username = secret.username
        mailSender.password = secret.password
    }
}

Obviously the default implmentation should remain as-is and use config, but I would like to inject my credential manager accordingly. Thanks!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions