From ae324704bbd9d52cbbcbd00b0d28cd79ec83b6c6 Mon Sep 17 00:00:00 2001 From: Brad Rydzewski Date: Wed, 2 Sep 2015 16:52:59 -0700 Subject: [PATCH] moved to drone-exec --- Makefile | 6 ++++++ make.go | 2 -- pkg/runner/builtin/runner.go | 4 ++-- pkg/runner/builtin/worker.go | 9 ++------- 4 files changed, 10 insertions(+), 11 deletions(-) diff --git a/Makefile b/Makefile index 58694db59..ff91a9414 100644 --- a/Makefile +++ b/Makefile @@ -3,6 +3,12 @@ SHA := $(shell git rev-parse --short HEAD) VERSION := 0.4.0-alpha +all: build + +build: + go run make.go bindata build + + # Execute the database test suite against mysql 5.5 # # You can launch a mysql container locally for testing: diff --git a/make.go b/make.go index c9a4cd355..8c80aa026 100644 --- a/make.go +++ b/make.go @@ -182,7 +182,6 @@ func build() error { }{ {"github.com/drone/drone/cmd/drone-server", "bin/drone"}, {"github.com/drone/drone/cmd/drone-agent", "bin/drone-agent"}, - {"github.com/drone/drone/cmd/drone-build", "bin/drone-build"}, } for _, bin := range bins { ldf := fmt.Sprintf("-X main.revision=%s -X main.version=%s", sha, version) @@ -267,7 +266,6 @@ func clean() error { files := []string{ "bin/drone", "bin/drone-agent", - "bin/drone-build", } for _, file := range files { diff --git a/pkg/runner/builtin/runner.go b/pkg/runner/builtin/runner.go index 1b101f171..63de47297 100644 --- a/pkg/runner/builtin/runner.go +++ b/pkg/runner/builtin/runner.go @@ -144,7 +144,7 @@ func (r *Runner) Run(w *queue.Work) error { Repo: w.Repo, Build: w.Build, Job: job, - Yaml: w.Yaml, + Yaml: string(w.Yaml), } in, err := json.Marshal(work) if err != nil { @@ -224,7 +224,7 @@ func (r *Runner) Run(w *queue.Work) error { Repo: w.Repo, Build: w.Build, Job: job, - Yaml: w.Yaml, + Yaml: string(w.Yaml), } in, err := json.Marshal(work) if err != nil { diff --git a/pkg/runner/builtin/worker.go b/pkg/runner/builtin/worker.go index bff4fd814..1d1583fa0 100644 --- a/pkg/runner/builtin/worker.go +++ b/pkg/runner/builtin/worker.go @@ -32,7 +32,7 @@ var ( DefaultAgent = "drone/drone-exec:latest" // default name of the build agent executable - DefaultEntrypoint = []string{"/bin/drone-build"} + DefaultEntrypoint = []string{"/bin/drone-exec"} // default argument to invoke build steps DefaultBuildArgs = []string{"--cache", "--clone", "--build", "--deploy"} @@ -50,12 +50,7 @@ type work struct { Job *types.Job `json:"job"` System *types.System `json:"system"` Workspace *types.Workspace `json:"workspace"` - Yaml []byte `json:"yaml"` - - // Keys *types.Keypair `json:"keys"` // remove - // Netrc *types.Netrc `json:"netrc"` // remove - // Env []string `json:"environment"` // remove - // Plugins []string `json:"plugins"` // remove + Yaml string `json:"yaml"` } type worker struct {