Initial config for building the plugin itself
This commit is contained in:
parent
6b121047e1
commit
ba75a9b1d8
22
.drone.yml
Normal file
22
.drone.yml
Normal file
|
@ -0,0 +1,22 @@
|
|||
kind: pipeline
|
||||
type: docker
|
||||
name: default
|
||||
|
||||
|
||||
steps:
|
||||
- name: test
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- go vet ./...
|
||||
- name: build
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- go build -o build/drone-helm cmd/drone-helm/main.go
|
||||
- name: publish
|
||||
image: plugins/docker
|
||||
auto_tag: true
|
||||
settings:
|
||||
dockerfile: Dockerfile
|
||||
registry: '192.168.0.17:5000'
|
||||
repo: 192.168.0.17:5000/drone-helm3
|
||||
insecure: true
|
9
Dockerfile
Normal file
9
Dockerfile
Normal file
|
@ -0,0 +1,9 @@
|
|||
FROM alpine/helm
|
||||
MAINTAINER Erin Call <erin@liffft.com>
|
||||
|
||||
COPY build/drone-helm /bin/drone-helm
|
||||
|
||||
LABEL description="Helm 3 plugin for Drone 3"
|
||||
LABEL base="alpine/helm"
|
||||
|
||||
ENTRYPOINT [ "/bin/drone-helm" ]
|
|
@ -1,3 +1,8 @@
|
|||
# Drone plugin for Helm 3
|
||||
|
||||
TODO: useful information in this README
|
||||
TODO:
|
||||
|
||||
* [x] Make a `.drone.yml` that's sufficient for building an image
|
||||
* [x] Make a `Dockerfile` that's sufficient for launching the built image
|
||||
* [ ] Make `cmd/drone-helm/main.go` actually invoke `helm`
|
||||
* [ ] Change `.drone.yml` to use a real docker registry
|
||||
|
|
1
cmd/drone-helm/.gitignore
vendored
Normal file
1
cmd/drone-helm/.gitignore
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
drone-helm
|
35
cmd/drone-helm/main.go
Normal file
35
cmd/drone-helm/main.go
Normal file
|
@ -0,0 +1,35 @@
|
|||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"os"
|
||||
|
||||
"github.com/urfave/cli"
|
||||
)
|
||||
|
||||
func main() {
|
||||
_ = fmt.Println
|
||||
_ = os.Exit
|
||||
|
||||
app := cli.NewApp()
|
||||
app.Name = "helm plugin"
|
||||
app.Usage = "helm plugin"
|
||||
app.Action = run
|
||||
app.Version = "0.0.1α"
|
||||
app.Flags = []cli.Flag{
|
||||
cli.StringFlag{
|
||||
Name: "echo, e",
|
||||
Usage: "this text'll be ech'll",
|
||||
EnvVar: "ECHO",
|
||||
},
|
||||
}
|
||||
|
||||
if err := app.Run(os.Args); err != nil {
|
||||
fmt.Fprintf(os.Stderr, "%s\n", err.Error())
|
||||
}
|
||||
}
|
||||
|
||||
func run(c *cli.Context) error {
|
||||
fmt.Println(c.String("echo"))
|
||||
return nil
|
||||
}
|
5
go.mod
Normal file
5
go.mod
Normal file
|
@ -0,0 +1,5 @@
|
|||
module github.com/pelotech/drone-helm3
|
||||
|
||||
go 1.13
|
||||
|
||||
require github.com/urfave/cli v1.22.0
|
9
go.sum
Normal file
9
go.sum
Normal file
|
@ -0,0 +1,9 @@
|
|||
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
|
||||
github.com/cpuguy83/go-md2man v1.0.10 h1:BSKMNlYxDvnunlTymqtgONjNnaRV1sTpcovwwjF22jk=
|
||||
github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE=
|
||||
github.com/russross/blackfriday v1.5.2 h1:HyvC0ARfnZBqnXwABFeSZHpKvJHJJfPz81GNueLj0oo=
|
||||
github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g=
|
||||
github.com/urfave/cli v1.22.0 h1:8nz/RUUotroXnOpYzT/Fy3sBp+2XEbXaY641/s3nbFI=
|
||||
github.com/urfave/cli v1.22.0/go.mod h1:b3D7uWrF2GilkNgYpgcg6J+JMUw7ehmNkE8sZdliGLc=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
Loading…
Reference in a new issue