Skip to content

Commit 71eca57

Browse files
committed
Merge branch 'GorillaStack-docker'
2 parents c6610db + 25d27a6 commit 71eca57

File tree

2 files changed

+27
-0
lines changed

2 files changed

+27
-0
lines changed

Dockerfile

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
FROM golang:1.8
2+
3+
ENV PORT_NUM 9200
4+
WORKDIR /go/src/app
5+
COPY . .
6+
7+
RUN go-wrapper download
8+
RUN go-wrapper install
9+
RUN go build -o aws-es-proxy
10+
11+
EXPOSE ${PORT_NUM}
12+
13+
CMD ["./aws-es-proxy", "-h"]

README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,20 @@ Usage of ./aws-es-proxy:
107107
Print user requests
108108
```
109109

110+
## Docker
111+
112+
There is a docker image avaiable for aws-es-proxy. There is an image on docker hub called `gorillastack/aws-es-proxy`. To run the image:
113+
114+
```sh
115+
# Prints usage info (-h)
116+
docker run --rm -it gorillastack/aws-es-proxy
117+
118+
# Runs with custom command/args
119+
docker run --rm -it gorillastack/aws-es-proxy ./aws-es-proxy -endpoint https://dummy-host.ap-southeast-2.es.amazonaws.com
120+
```
121+
122+
To expose a port number other than the default 9200, pass an environment variable of `PORT_NUM` to docker with the port number you wish to expose for your service.
123+
110124
## Using HTTP Clients
111125

112126
After you run *aws-es-proxy*, you can now open your Web browser on [http://localhost:9200](http://localhost:9200). Everything should be working as you have your own instance of ElasticSearch running on port 9200.

0 commit comments

Comments
 (0)