diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..6cabbe2 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,6 @@ +FROM golang:1.12-alpine3.9 +WORKDIR /go/src/github.com/suyashkumar/ssl-proxy +RUN apk add --no-cache make git zip +RUN go get -u github.com/golang/dep/cmd/dep +COPY . . +RUN make diff --git a/README.md b/README.md index 30a78eb..e8292d0 100644 --- a/README.md +++ b/README.md @@ -37,8 +37,17 @@ If you're using `wget`, you can fetch and uncompress the proper binary in one co wget -qO- $BINARY_RELEASE_LINK | tar xvz ``` -### Build from source -You must have Golang installed on your system along with `make` and [`dep`](https://github.com/golang/dep). Then simply clone the repository and run `make`. +### Build from source +#### Build from source using Docker +You can build `ssl-proxy` for all platforms quickly using the included Docker configurations. + +If you have `docker-compose` installed: +```sh +docker-compose -f docker-compose.build.yml up +``` +will build linux, osx, and darwin binaries (x86) and place them in a `build/` folder in your current working directory. +#### Build from source locally +You must have Golang installed on your system along with `make` and [`dep`](https://github.com/golang/dep). Then simply clone the repository and run `make`. ## Attribution Icons made by Those Icons from www.flaticon.com is licensed by CC 3.0 BY diff --git a/docker-compose.build.yml b/docker-compose.build.yml new file mode 100644 index 0000000..3d3b6eb --- /dev/null +++ b/docker-compose.build.yml @@ -0,0 +1,7 @@ +version: '2' +services: + build-release: + build: . + volumes: + - $PWD/build:/go/src/github.com/suyashkumar/ssl-proxy/build + command: make release