Skip to content

Commit d1017c0

Browse files
author
Dave Tucker
committedFeb 6, 2015
Update Fig with Docker Compose
This allows us to use --cap-add NET_ADMIN for the OVS container Signed-off-by: Dave Tucker <[email protected]>
1 parent d7a3167 commit d1017c0

File tree

3 files changed

+9
-11
lines changed

3 files changed

+9
-11
lines changed
 

‎HACKING.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ How to contribute to SocketPlane
77

88
- [Golang](http://golang.org/doc/code.html)
99
- [Docker](https://docs.docker.com/installation/#installation)
10-
- [Fig](http://www.fig.sh/install.html)
10+
- [Docker Compose](http://www.fig.sh/install.html)
1111

1212
The system running Docker must have the `openvswitch` kernel module must be loaded for the test suite to be run. You can load it using `modprobe openvswitch`
1313

‎Makefile

+6-6
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@ coverage:
88
goveralls -coverprofile=socketplane.coverprofile -service=$(CI_SERVICE) -repotoken=$(COVERALLS_TOKEN)
99

1010
test:
11-
fig up -d
12-
docker run --cap-add=NET_ADMIN --net=container:socketplane_ovs_1 --rm -v $(shell pwd):/go/src/github.com/socketplane/socketplane -w /go/src/github.com/socketplane/socketplane davetucker/golang-ci:1.3 make test-local
13-
fig stop
11+
docker-compose up -d
12+
docker run --cap-add=NET_ADMIN --cap-add SYS_ADMIN --net=container:socketplane_ovs_1 --rm -v $(shell pwd):/go/src/github.com/socketplane/socketplane -w /go/src/github.com/socketplane/socketplane davetucker/golang-ci:1.3 make test-local
13+
docker-compose stop
1414

1515
test-all:
16-
fig up -d
17-
docker run --cap-add=NET_ADMIN --net=container:socketplane_ovs_1 --rm -v $(shell pwd):/go/src/github.com/socketplane/socketplane -w /go/src/github.com/socketplane/socketplane davetucker/golang-ci:1.3 make test-all-local
18-
fig stop
16+
docker-compose up -d
17+
docker run --cap-add=NET_ADMIN --cap-add SYS_ADMIN --net=container:socketplane_ovs_1 --rm -v $(shell pwd):/go/src/github.com/socketplane/socketplane -w /go/src/github.com/socketplane/socketplane davetucker/golang-ci:1.3 make test-all-local
18+
docker-compose stop
1919

2020
test-local:
2121
go test -covermode=count -test.short -coverprofile=daemon.cover.out -coverpkg=./... ./daemon

‎fig.yml ‎docker-compose.yml

+2-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
ovs:
22
image: davetucker/docker-ovs:2.3.0
3-
net: "host"
4-
ports:
5-
- "6640:6640"
63
command: "/usr/bin/supervisord -n"
7-
privileged: true
4+
cap_add:
5+
- NET_ADMIN

0 commit comments

Comments
 (0)
Please sign in to comment.