use major version in image name

This commit is contained in:
Brad Rydzewski 2019-12-13 08:14:10 -08:00
parent 9c9b99bd70
commit 45a3181f50
2 changed files with 2 additions and 11 deletions

View file

@ -212,7 +212,7 @@ type (
// Runner provides the runner configuration. // Runner provides the runner configuration.
Runner struct { Runner struct {
Local bool `envconfig:"DRONE_RUNNER_LOCAL"` Local bool `envconfig:"DRONE_RUNNER_LOCAL"`
Image string `envconfig:"DRONE_RUNNER_IMAGE" default:"drone/controller:1.0.0"` Image string `envconfig:"DRONE_RUNNER_IMAGE" default:"drone/controller:1"`
Platform string `envconfig:"DRONE_RUNNER_PLATFORM" default:"linux/amd64"` Platform string `envconfig:"DRONE_RUNNER_PLATFORM" default:"linux/amd64"`
OS string `envconfig:"DRONE_RUNNER_OS"` OS string `envconfig:"DRONE_RUNNER_OS"`
Arch string `envconfig:"DRONE_RUNNER_ARCH"` Arch string `envconfig:"DRONE_RUNNER_ARCH"`

View file

@ -6,16 +6,7 @@
package internal package internal
import ( var defaultImage = "drone/controller:1"
"fmt"
"github.com/drone/drone/version"
)
var defaultImage = fmt.Sprintf(
"drone/controller:%s",
version.Version.String(),
)
// DefaultImage returns the default dispatch image if none // DefaultImage returns the default dispatch image if none
// is specified. // is specified.