Skip to content

Commit

Permalink
Merge pull request #9 from dpp23/setup-container-timeout-config
Browse files Browse the repository at this point in the history
Use timeout config for the init container timeout
  • Loading branch information
joyrex2001 authored Feb 20, 2022
2 parents e9b93df + e378dae commit 326a515
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions internal/backend/deploy.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ func (in *instance) StartContainer(tainr *types.Container) (DeployState, error)
}

if tainr.HasVolumes() {
if err := in.copyVolumeFolders(tainr); err != nil {
if err := in.copyVolumeFolders(tainr, in.timeOut); err != nil {
return DeployFailed, err
}
}
Expand Down Expand Up @@ -497,8 +497,8 @@ func (in *instance) createConfigMapFromRaw(tainr *types.Container, files map[str
// copyVolumeFolders will copy the configured volumes of the container to
// the running init container, and signal the init container when finished
// with copying.
func (in *instance) copyVolumeFolders(tainr *types.Container) error {
if err := in.waitInitContainerRunning(tainr, "setup", 30); err != nil {
func (in *instance) copyVolumeFolders(tainr *types.Container, wait int) error {
if err := in.waitInitContainerRunning(tainr, "setup", wait); err != nil {
return err
}

Expand Down

0 comments on commit 326a515

Please sign in to comment.