Skip to content

Commit

Permalink
feat(pool, volume): add image pull secrets to pool and volume deploym…
Browse files Browse the repository at this point in the history
…ent (#225)

* add a method to get image pull secrets from env
* add image pull secrets to pool and volume pods

Signed-off-by: Akhil Mohan <[email protected]>
  • Loading branch information
akhilerm authored and kmova committed Jan 12, 2021
1 parent 4d9034f commit 44f6a9a
Show file tree
Hide file tree
Showing 8 changed files with 67 additions and 5 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ require (
github.com/imdario/mergo v0.3.8 // indirect
github.com/onsi/ginkgo v1.12.0
github.com/onsi/gomega v1.9.0
github.com/openebs/api/v2 v2.1.0
github.com/openebs/api/v2 v2.2.0
github.com/pkg/errors v0.9.1
github.com/spf13/cobra v0.0.5
github.com/spf13/pflag v1.0.5
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -387,8 +387,8 @@ github.com/opencontainers/image-spec v1.0.1/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zM
github.com/opencontainers/runc v1.0.0-rc9/go.mod h1:qT5XzbpPznkRYVz/mWwUaVBUv2rmF59PVA73FjuZG0U=
github.com/opencontainers/runtime-spec v1.0.0/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0=
github.com/opencontainers/selinux v1.3.1-0.20190929122143-5215b1806f52/go.mod h1:+BLncwf63G4dgOzykXAxcmnFlUaOlkDdmw/CqsW6pjs=
github.com/openebs/api/v2 v2.1.0 h1:2DPzT93t2r76MXTUGbTCcBIhM5x+KXDsC04cNossMLU=
github.com/openebs/api/v2 v2.1.0/go.mod h1:CTvN3qWesanPiu7KWouKPN70nL4DyUwITfyjiO/85cs=
github.com/openebs/api/v2 v2.2.0 h1:JKB6vRTKveMmmouPv6gKfnvca13XU2yvZC/KQm2PR9I=
github.com/openebs/api/v2 v2.2.0/go.mod h1:CTvN3qWesanPiu7KWouKPN70nL4DyUwITfyjiO/85cs=
github.com/pborman/uuid v1.2.0/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k=
github.com/pelletier/go-toml v1.1.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
Expand Down
1 change: 1 addition & 0 deletions pkg/controllers/cstorvolumeconfig/deployment.go
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,7 @@ func (c *CVCController) BuildTargetDeployment(
WithPriorityClassName(getPriorityClass(policySpec)).
WithNodeSelectorByValue(policySpec.Target.NodeSelector).
WithTolerationsNew(getDeployTolerations(policySpec)...).
WithImagePullSecrets(apicore.GetImagePullSecrets(util.GetOpenEBSImagePullSecrets())).
WithContainers(
apicore.NewContainer().
WithImage(getVolumeTargetImage()).
Expand Down
1 change: 1 addition & 0 deletions pkg/cspc/algorithm/build_deploy.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ func (c *Config) GetPoolDeploySpec(cspi *cstor.CStorPoolInstance) *appsv1.Deploy
WithAnnotationsNew(getPodAnnotations()).
WithServiceAccountName(util.GetServiceAccountName()).
WithTolerations(getPoolPodToleration(cspi)...).
WithImagePullSecrets(coreapi.GetImagePullSecrets(util.GetOpenEBSImagePullSecrets())).
WithContainers(
coreapi.NewContainer().
WithImage(getPoolMgmtImage()).
Expand Down
10 changes: 10 additions & 0 deletions vendor/github.com/openebs/api/v2/pkg/kubernetes/core/pod.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

42 changes: 42 additions & 0 deletions vendor/github.com/openebs/api/v2/pkg/kubernetes/core/secret.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 9 additions & 1 deletion vendor/github.com/openebs/api/v2/pkg/util/env.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ github.com/onsi/gomega/matchers/support/goraph/edge
github.com/onsi/gomega/matchers/support/goraph/node
github.com/onsi/gomega/matchers/support/goraph/util
github.com/onsi/gomega/types
# github.com/openebs/api/v2 v2.1.0
# github.com/openebs/api/v2 v2.2.0
github.com/openebs/api/v2/pkg/apis/cstor
github.com/openebs/api/v2/pkg/apis/cstor/v1
github.com/openebs/api/v2/pkg/apis/openebs.io
Expand Down

0 comments on commit 44f6a9a

Please sign in to comment.