Skip to content
This repository was archived by the owner on Feb 10, 2025. It is now read-only.

Commit a1fc42e

Browse files
authored
Using go dep (#26)
* Using go dep * Separate dependecy and application docker layers * Empty line
1 parent b46644f commit a1fc42e

File tree

404 files changed

+141
-196519
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

404 files changed

+141
-196519
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
rabbit-amazon-forwarder
22
samples
3+
vendor/

Dockerfile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
FROM golang:1.9.2-alpine3.6 AS golang-build
22
RUN mkdir -p /go/src/github.com/AirHelp/rabbit-amazon-forwarder
33
WORKDIR /go/src/github.com/AirHelp/rabbit-amazon-forwarder
4+
RUN apk --no-cache add git && go get -u github.com/golang/dep/cmd/dep
5+
COPY Gopkg.toml Gopkg.lock ./
6+
RUN dep ensure -v -vendor-only
47
COPY . .
58
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o rabbit-amazon-forwarder .
69

Dockerfile-test

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,7 @@
11
FROM golang:1.9.2-alpine3.6
22
WORKDIR /go/src/github.com/AirHelp/rabbit-amazon-forwarder
3+
RUN apk --no-cache add git && go get -u github.com/golang/dep/cmd/dep
4+
COPY Gopkg.toml Gopkg.lock ./
5+
RUN dep ensure -v -vendor-only
6+
COPY . .
7+

Gopkg.lock

Lines changed: 89 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Gopkg.toml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# Gopkg.toml example
2+
#
3+
# Refer to https://github.com/golang/dep/blob/master/docs/Gopkg.toml.md
4+
# for detailed Gopkg.toml documentation.
5+
#
6+
# required = ["github.com/user/thing/cmd/thing"]
7+
# ignored = ["github.com/user/project/pkgX", "bitbucket.org/user/project/pkgA/pkgY"]
8+
#
9+
# [[constraint]]
10+
# name = "github.com/user/project"
11+
# version = "1.0.0"
12+
#
13+
# [[constraint]]
14+
# name = "github.com/user/project2"
15+
# branch = "dev"
16+
# source = "github.com/myfork/project2"
17+
#
18+
# [[override]]
19+
# name = "github.com/x/y"
20+
# version = "2.4.0"
21+
#
22+
# [prune]
23+
# non-go = false
24+
# go-tests = true
25+
# unused-packages = true
26+
27+
28+
[[constraint]]
29+
name = "github.com/aws/aws-sdk-go"
30+
version = "1.14.7"
31+
32+
[[constraint]]
33+
name = "github.com/sirupsen/logrus"
34+
version = "1.0.5"
35+
36+
[[constraint]]
37+
branch = "master"
38+
name = "github.com/streadway/amqp"
39+
40+
[prune]
41+
go-tests = true
42+
unused-packages = true

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ When making subscription to SNS -> SQS/HTTP/HTTPS set `Raw message delivery` to
6262
## Build docker image
6363

6464
```bash
65-
make release
65+
make build
6666
```
6767

6868
## Run

docker-compose.yml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@ services:
1616
context: .
1717
dockerfile: Dockerfile-test
1818
command: go test ./...
19-
volumes:
20-
- ./:/go/src/github.com/AirHelp/rabbit-amazon-forwarder
2119
depends_on:
2220
- fmt
2321
- vet
@@ -26,12 +24,8 @@ services:
2624
context: .
2725
dockerfile: Dockerfile-test
2826
command: go vet -v ./...
29-
volumes:
30-
- .:/go/src/github.com/AirHelp/rabbit-amazon-forwarder
3127
fmt:
3228
build:
3329
context: .
3430
dockerfile: Dockerfile-test
3531
command: gofmt ./...
36-
volumes:
37-
- .:/go/src/github.com/AirHelp/rabbit-amazon-forwarder

vendor/github.com/aws/aws-sdk-go/LICENSE.txt

Lines changed: 0 additions & 202 deletions
This file was deleted.

vendor/github.com/aws/aws-sdk-go/NOTICE.txt

Lines changed: 0 additions & 3 deletions
This file was deleted.

0 commit comments

Comments
 (0)