Added docker-compose.travis.yml

This commit is contained in:
Michael Mayer 2018-02-28 10:31:10 +01:00
parent 8b48928d7f
commit 91eae960c6
2 changed files with 21 additions and 3 deletions

View file

@ -4,11 +4,10 @@ services:
- docker
before_script:
- docker-compose build
- docker-compose up -d
- docker-compose -f docker-compose.travis.yml up --build -d
script:
- docker-compose exec photoprism /usr/local/go/bin/go test
after_script:
- docker-compose down
- docker-compose -f docker-compose.travis.yml down

19
docker-compose.travis.yml Normal file
View file

@ -0,0 +1,19 @@
version: '3.3'
services:
photoprism:
build: .
database:
image: mysql:latest
command: mysqld --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci --max-connections=1024
volumes:
- database-data:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: photoprism
MYSQL_USER: photoprism
MYSQL_PASSWORD: photoprism
MYSQL_DATABASE: photoprism
volumes:
database-data:
driver: local