summaryrefslogtreecommitdiff
path: root/pkg/domain/infra/abi/secrets.go
diff options
context:
space:
mode:
authorAshley Cui <acui@redhat.com>2022-09-09 10:57:45 -0400
committerPaul Holzinger <pholzing@redhat.com>2022-09-12 18:05:17 +0200
commit72e715a1109426114ef054042be28014380a246d (patch)
treef37bdb7e103f4a8443d7fb8d0e3845d019ad0a67 /pkg/domain/infra/abi/secrets.go
parentcd32b929e35cdb2d6b49853a7b0e5d93921b0979 (diff)
downloadpodman-72e715a1109426114ef054042be28014380a246d.tar.gz
podman-72e715a1109426114ef054042be28014380a246d.tar.bz2
podman-72e715a1109426114ef054042be28014380a246d.zip
Use new secret store API
Refactored secrets API in common for stability purposes. Move podman to said API. [NO NEW TESTS NEEDED] Signed-off-by: Ashley Cui <acui@redhat.com>
Diffstat (limited to 'pkg/domain/infra/abi/secrets.go')
-rw-r--r--pkg/domain/infra/abi/secrets.go8
1 files changed, 7 insertions, 1 deletions
diff --git a/pkg/domain/infra/abi/secrets.go b/pkg/domain/infra/abi/secrets.go
index e17de5a8c..47159d65a 100644
--- a/pkg/domain/infra/abi/secrets.go
+++ b/pkg/domain/infra/abi/secrets.go
@@ -8,6 +8,7 @@ import (
"path/filepath"
"strings"
+ "github.com/containers/common/pkg/secrets"
"github.com/containers/podman/v4/pkg/domain/entities"
"github.com/containers/podman/v4/pkg/domain/utils"
)
@@ -42,10 +43,15 @@ func (ic *ContainerEngine) SecretCreate(ctx context.Context, name string, reader
}
}
- secretID, err := manager.Store(name, data, options.Driver, options.DriverOpts, nil)
+ storeOpts := secrets.StoreOptions{
+ DriverOpts: options.DriverOpts,
+ }
+
+ secretID, err := manager.Store(name, data, options.Driver, storeOpts)
if err != nil {
return nil, err
}
+
return &entities.SecretCreateReport{
ID: secretID,
}, nil