Merge pull request #218 from drone-plugins/readme-fixes
Add proper instructions to readme
This commit is contained in:
commit
5bc9ff8d9b
@ -72,6 +72,14 @@ local PipelineBuild(binary="docker", os="linux", arch="amd64") = {
|
||||
event: [ "tag" ],
|
||||
},
|
||||
},
|
||||
if binary == "docker" then {
|
||||
name: "executable",
|
||||
image: "golang:1.11",
|
||||
pull: "always",
|
||||
commands: [
|
||||
"./release/" + os + "/" + arch + "/drone-" + binary + " --help",
|
||||
],
|
||||
},
|
||||
{
|
||||
name: "dryrun",
|
||||
image: "plugins/docker:" + os + "-" + arch,
|
||||
|
@ -32,6 +32,12 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: executable
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- ./release/windows/amd64/drone-docker --help
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:windows-amd64
|
||||
|
18
.drone.yml
18
.drone.yml
@ -61,6 +61,12 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: executable
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- ./release/linux/amd64/drone-docker --help
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:linux-amd64
|
||||
@ -135,6 +141,12 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: executable
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- ./release/linux/arm64/drone-docker --help
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:linux-arm64
|
||||
@ -209,6 +221,12 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: executable
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- ./release/linux/arm/drone-docker --help
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:linux-arm
|
||||
|
4
.github/settings.yml
vendored
4
.github/settings.yml
vendored
@ -58,7 +58,6 @@ branches:
|
||||
dismissal_restrictions:
|
||||
teams:
|
||||
- Admins
|
||||
- Captain
|
||||
required_status_checks:
|
||||
strict: true
|
||||
contexts:
|
||||
@ -66,4 +65,5 @@ branches:
|
||||
enforce_admins: false
|
||||
restrictions:
|
||||
users: []
|
||||
teams: []
|
||||
teams:
|
||||
- Admins
|
||||
|
38
README.md
38
README.md
@ -8,22 +8,50 @@
|
||||
[![Go Doc](https://godoc.org/github.com/drone-plugins/drone-docker?status.svg)](http://godoc.org/github.com/drone-plugins/drone-docker)
|
||||
[![Go Report](https://goreportcard.com/badge/github.com/drone-plugins/drone-docker)](https://goreportcard.com/report/github.com/drone-plugins/drone-docker)
|
||||
|
||||
Drone plugin to build and publish Docker images to a container registry.
|
||||
Drone plugin to build and publish Docker images to a container registry. For the usage information and a listing of the available options please take a look at [the docs](http://plugins.drone.io/drone-plugins/drone-docker/).
|
||||
|
||||
## Build
|
||||
|
||||
Build the binary with the following commands:
|
||||
Build the binaries with the following commands:
|
||||
|
||||
```
|
||||
sh .drone.sh
|
||||
export GOOS=linux
|
||||
export GOARCH=amd64
|
||||
export CGO_ENABLED=0
|
||||
export GO111MODULE=on
|
||||
|
||||
go test -cover ./...
|
||||
|
||||
go build -v -a -tags netgo -o release/linux/amd64/drone-docker ./cmd/drone-docker
|
||||
go build -v -a -tags netgo -o release/linux/amd64/drone-gcr ./cmd/drone-gcr
|
||||
go build -v -a -tags netgo -o release/linux/amd64/drone-ecr ./cmd/drone-ecr
|
||||
go build -v -a -tags netgo -o release/linux/amd64/drone-heroku ./cmd/drone-heroku
|
||||
```
|
||||
|
||||
## Docker
|
||||
|
||||
Build the Docker image with the following commands:
|
||||
Build the Docker images with the following commands:
|
||||
|
||||
```
|
||||
docker build --rm=true -f docker/Dockerfile -t plugins/docker .
|
||||
docker build \
|
||||
--label org.label-schema.build-date=$(date -u +"%Y-%m-%dT%H:%M:%SZ") \
|
||||
--label org.label-schema.vcs-ref=$(git rev-parse --short HEAD) \
|
||||
--file docker/docker/Dockerfile.linux.amd64 --tag plugins/docker .
|
||||
|
||||
docker build \
|
||||
--label org.label-schema.build-date=$(date -u +"%Y-%m-%dT%H:%M:%SZ") \
|
||||
--label org.label-schema.vcs-ref=$(git rev-parse --short HEAD) \
|
||||
--file docker/gcr/Dockerfile.linux.amd64 --tag plugins/gcr .
|
||||
|
||||
docker build \
|
||||
--label org.label-schema.build-date=$(date -u +"%Y-%m-%dT%H:%M:%SZ") \
|
||||
--label org.label-schema.vcs-ref=$(git rev-parse --short HEAD) \
|
||||
--file docker/ecr/Dockerfile.linux.amd64 --tag plugins/ecr .
|
||||
|
||||
docker build \
|
||||
--label org.label-schema.build-date=$(date -u +"%Y-%m-%dT%H:%M:%SZ") \
|
||||
--label org.label-schema.vcs-ref=$(git rev-parse --short HEAD) \
|
||||
--file docker/heroku/Dockerfile.linux.amd64 --tag plugins/heroku .
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
Loading…
Reference in New Issue
Block a user