Skip to content
This repository has been archived by the owner on Dec 9, 2022. It is now read-only.

Commit

Permalink
Merge pull request #46 from deliveroo/revert-45-CPR-569/add-cleanup-p…
Browse files Browse the repository at this point in the history
…ods-command

Revert "CPR-569: New command to delete all finished pods"
  • Loading branch information
Barabasi Csongor authored Jun 22, 2020
2 parents 0655d7a + aa98113 commit 08e61d7
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 98 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.0.6-test
0.21.3
16 changes: 0 additions & 16 deletions cli/cleanup/cmd.go

This file was deleted.

75 changes: 0 additions & 75 deletions cli/cleanup/pods.go

This file was deleted.

5 changes: 1 addition & 4 deletions cli/pipeline/template.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,8 @@ package pipeline
import (
"bytes"
"fmt"
"strconv"
"strings"
"text/template"
"time"
)

type PodSecret struct {
Expand Down Expand Up @@ -193,8 +191,7 @@ func NewPodDefinition(pipelineDefinition *PipelineDefinition, pipelineDefinition
stepName := sanitizeName(pipelineDefinitionStep.Step)
branchName := sanitizeName(pipelineDefinitionStep.Branch)
stepVersion := sanitizeName(pipelineDefinitionStep.Version)
timestamp := strconv.Itoa(int(time.Now().UTC().Unix()))
podName := fmt.Sprintf("%s-%s-%s-%s-%s", sanitizeName(pipelineDefinition.Pipeline), sanitizeName(pipelineDefinitionStep.Version), stepName, branchName, timestamp[len(timestamp)-4:])
podName := fmt.Sprintf("%s-%s-%s-%s", sanitizeName(pipelineDefinition.Pipeline), sanitizeName(pipelineDefinitionStep.Version), stepName, branchName)

return &PodDefinition{
PodName: podName,
Expand Down
2 changes: 0 additions & 2 deletions cli/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ import (
"fmt"
"os"

"github.com/deliveroo/paddle/cli/cleanup"
"github.com/deliveroo/paddle/cli/data"
"github.com/deliveroo/paddle/cli/pipeline"
"github.com/deliveroo/paddle/cli/steps"
Expand Down Expand Up @@ -59,7 +58,6 @@ func init() {
RootCmd.AddCommand(data.DataCmd)
RootCmd.AddCommand(pipeline.PipelineCmd)
RootCmd.AddCommand(steps.StepsCmd)
RootCmd.AddCommand(cleanup.CleanUpCmd)
}

// initConfig reads in config file and ENV variables if set.
Expand Down

0 comments on commit 08e61d7

Please sign in to comment.