CI service command

This commit is contained in:
Antoine Legrand 2017-07-28 13:23:31 +02:00
parent 7cc39a7c54
commit f3ac04f799
3 changed files with 94 additions and 77 deletions

View file

@ -101,15 +101,25 @@ function(vars={})
},
EndToEndTest: self.QuayTest {
initDb:: true,
services: [
"postgres:9.6",
vars.images.quayci.name,
],
before_script+: [
"sleep 30",
"alembic upgrade head",
],
{name: "postgres:9.6"},
{name: vars.images.quayci.name, alias: 'quay'}
] + if self.initDb == true then [
{name: vars.images.quayci.name,
alias: 'db-init',
command: ["/bin/sh",
"-c",
"sleep 30" +
"&& /quay-registry/venv/bin/python initdb.py" +
"&& sleep 3600",]},
] else [],
before_script: if self.image == vars.images.quayci.name
then super.before_script
else [],
script: ['sleep 150'],
variables+: {
APP_HOST: "localhost:80",
POSTGRES_PASSWORD: "quay",
POSTGRES_USER: "quay",
SKIP_DB_SCHEMA: 'true',