Files
moby/daemon/secrets.go
Sebastiaan van Stijn 77f97926ad daemon: remove secretsSupported utility
This utility was originally added in 3716ec25b4
at which time it was not yet implemented for Windows, so this utility was
used to print a warning when trying to use it on that platform.

Windows support was added in bd4e8aa64e, which
kept the utility, but adjusted it to support for both Windows and Linux, and
excluding any other platform.

Let's remove this utility, given that we currently only support Windows and
Linux (there's been some partial support for other platforms, but they are
very likely broken in many ways).

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2024-10-20 14:10:17 +02:00

16 lines
422 B
Go

package daemon // import "github.com/docker/docker/daemon"
import (
swarmtypes "github.com/docker/docker/api/types/swarm"
)
// SetContainerSecretReferences sets the container secret references needed
func (daemon *Daemon) SetContainerSecretReferences(name string, refs []*swarmtypes.SecretReference) error {
c, err := daemon.GetContainer(name)
if err != nil {
return err
}
c.SecretReferences = refs
return nil
}