50 lines
1.1 KiB
Text
50 lines
1.1 KiB
Text
|
function(vars={})
|
||
|
{
|
||
|
dockerBuild: {
|
||
|
// base job to manage containers (build / push)
|
||
|
variables: {
|
||
|
DOCKER_DRIVER: "aufs",
|
||
|
},
|
||
|
image: "docker:git",
|
||
|
before_script: [
|
||
|
"docker login -u $DOCKER_USER -p $DOCKER_PASS quay.io",
|
||
|
],
|
||
|
services: [
|
||
|
"docker:dind",
|
||
|
],
|
||
|
tags: [
|
||
|
"docker",
|
||
|
],
|
||
|
},
|
||
|
|
||
|
QuayTest: {
|
||
|
// base job to test the container
|
||
|
image: vars.images.quayci.name,
|
||
|
variables: {
|
||
|
TEST: "true",
|
||
|
PYTHONPATH: ".",
|
||
|
GIT_STRATEGY: "none",
|
||
|
},
|
||
|
before_script: [
|
||
|
"cd /",
|
||
|
"source venv/bin/activate",
|
||
|
],
|
||
|
tags: [
|
||
|
"kubernetes",
|
||
|
],
|
||
|
},
|
||
|
|
||
|
dbTest(scheme, image, env):: self.QuayTest {
|
||
|
variables+: {
|
||
|
SKIP_DB_SCHEMA: 'true',
|
||
|
TEST_DATABASE_URI: '%s://quay:quay@localhost/quay' % scheme,
|
||
|
} + env,
|
||
|
services: [image],
|
||
|
script: [
|
||
|
"sleep 30",
|
||
|
"alembic upgrade head",
|
||
|
'PYTHONPATH="." TEST="true" py.test --timeout=7200 --verbose --show-count ./ --color=no --ignore=endpoints/appr/test/ -x',
|
||
|
],
|
||
|
},
|
||
|
}
|