Move game server to port 8080 and host docs on 80
This commit is contained in:
parent
b121b4463e
commit
47921e6c41
5 changed files with 27 additions and 6 deletions
8
Dockerfile.docs
Normal file
8
Dockerfile.docs
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
FROM quay.io/goswagger/swagger:latest
|
||||||
|
LABEL maintainer="Marc Di Luzio <marc.diluzio@gmail.com>"
|
||||||
|
|
||||||
|
WORKDIR /app
|
||||||
|
COPY . .
|
||||||
|
|
||||||
|
CMD [ "serve", "swagger.yml", "--no-open" ]
|
||||||
|
|
3
Makefile
3
Makefile
|
@ -18,6 +18,9 @@ test:
|
||||||
@echo Integration tests
|
@echo Integration tests
|
||||||
docker-compose up --build --exit-code-from=rove-tests --abort-on-container-exit rove-tests
|
docker-compose up --build --exit-code-from=rove-tests --abort-on-container-exit rove-tests
|
||||||
go tool cover -html=/tmp/coverage-data/c.out -o /tmp/coverage.html
|
go tool cover -html=/tmp/coverage-data/c.out -o /tmp/coverage.html
|
||||||
|
|
||||||
|
@echo Validating swagger spec
|
||||||
|
swagger validate swagger.yml
|
||||||
|
|
||||||
@echo Done, coverage data can be found in /tmp/coverage.html
|
@echo Done, coverage data can be found in /tmp/coverage.html
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,7 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
defaultAddress = "localhost:80"
|
defaultAddress = "localhost:8080"
|
||||||
)
|
)
|
||||||
|
|
||||||
var serv = func() rove.Server {
|
var serv = func() rove.Server {
|
||||||
|
|
|
@ -13,7 +13,7 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
defaultAddress = "localhost:80"
|
defaultAddress = "localhost:8080"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Test_InnerMain(t *testing.T) {
|
func Test_InnerMain(t *testing.T) {
|
||||||
|
|
|
@ -18,16 +18,26 @@ services:
|
||||||
- persistent-data:/mnt/rove-server:rw
|
- persistent-data:/mnt/rove-server:rw
|
||||||
command: [ ./rove-accountant ]
|
command: [ ./rove-accountant ]
|
||||||
|
|
||||||
|
rove-docs:
|
||||||
|
build:
|
||||||
|
context: .
|
||||||
|
dockerfile: Dockerfile.docs
|
||||||
|
image: rove-docs:latest
|
||||||
|
ports:
|
||||||
|
- "80:80"
|
||||||
|
environment:
|
||||||
|
- PORT=80
|
||||||
|
|
||||||
rove-server:
|
rove-server:
|
||||||
depends_on: [ rove-accountant ]
|
depends_on: [ rove-accountant, rove-docs ]
|
||||||
build:
|
build:
|
||||||
context: .
|
context: .
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
image: rove:latest
|
image: rove:latest
|
||||||
ports:
|
ports:
|
||||||
- "80:80"
|
- "8080:8080"
|
||||||
environment:
|
environment:
|
||||||
- HOST_ADDRESS=:80
|
- HOST_ADDRESS=:8080
|
||||||
- DATA_PATH=/mnt/rove-server
|
- DATA_PATH=/mnt/rove-server
|
||||||
- ACCOUNTANT_ADDRESS=rove-accountant:8081
|
- ACCOUNTANT_ADDRESS=rove-accountant:8081
|
||||||
volumes:
|
volumes:
|
||||||
|
@ -41,7 +51,7 @@ services:
|
||||||
image: rove:latest
|
image: rove:latest
|
||||||
environment:
|
environment:
|
||||||
- ACCOUNTANT_ADDRESS=rove-accountant:8081
|
- ACCOUNTANT_ADDRESS=rove-accountant:8081
|
||||||
- ROVE_SERVER_ADDRESS=rove-server:80
|
- ROVE_SERVER_ADDRESS=rove-server:8080
|
||||||
command: [ "go", "test", "-v", "./...", "--tags=integration", "-cover", "-coverprofile=/mnt/coverage-data/c.out", "-count", "1" ]
|
command: [ "go", "test", "-v", "./...", "--tags=integration", "-cover", "-coverprofile=/mnt/coverage-data/c.out", "-count", "1" ]
|
||||||
volumes:
|
volumes:
|
||||||
- /tmp/coverage-data:/mnt/coverage-data:rw
|
- /tmp/coverage-data:/mnt/coverage-data:rw
|
||||||
|
|
Loading…
Add table
Reference in a new issue