only include KNAPSACK env vars when necessary

this avoids a bunch of warnings in the un-knapsacked builds

Change-Id: I5caf6bd94d5d7b3350a492b739f6d712c7e34829
Reviewed-on: https://gerrit.instructure.com/211667
Reviewed-by: James Williams <jamesw@instructure.com>
QA-Review: James Williams <jamesw@instructure.com>
Product-Review: James Williams <jamesw@instructure.com>
Tested-by: Jenkins
This commit is contained in:
Cameron Matheson 2019-10-01 12:27:33 -06:00
parent fd6e0972da
commit 56d89a3df4
4 changed files with 15 additions and 9 deletions

View File

@ -26,7 +26,7 @@ pipeline {
}
environment {
COMPOSE_FILE = 'docker-compose.new-jenkins.yml'
COMPOSE_FILE = 'docker-compose.new-jenkins.yml:docker-compose.new-jenkins-knapsack.yml'
// 'refs/changes/63/181863/8' -> '63.181863.8'
NAME = "${env.GERRIT_REFSPEC}".minus('refs/changes/').replaceAll('/','.')
PATCHSET_TAG = "$DOCKER_REGISTRY_FQDN/jenkins/canvas-lms:$NAME"

View File

@ -26,7 +26,7 @@ pipeline {
}
environment {
COMPOSE_FILE = 'docker-compose.new-jenkins.yml:docker-compose.new-jenkins-selenium.yml'
COMPOSE_FILE = 'docker-compose.new-jenkins.yml:docker-compose.new-jenkins-selenium.yml:docker-compose.new-jenkins-knapsack.yml'
// 'refs/changes/63/181863/8' -> '63.181863.8'
NAME = "${env.GERRIT_REFSPEC}".minus('refs/changes/').replaceAll('/','.')
PATCHSET_TAG = "$DOCKER_REGISTRY_FQDN/jenkins/canvas-lms:$NAME"

View File

@ -0,0 +1,13 @@
# it is intended that this be used exclusive of all other docker-compose.*yml files in CI
version: "2.3"
services:
web:
environment:
CI_NODE_TOTAL: $CI_NODE_TOTAL
CI_NODE_INDEX: $CI_NODE_INDEX
KNAPSACK_ENABLED: $KNAPSACK_ENABLED
KNAPSACK_TEST_FILE_PATTERN: $KNAPSACK_TEST_FILE_PATTERN
KNAPSACK_EXCLUDE_REGEX: $KNAPSACK_EXCLUDE_REGEX
KNAPSACK_TEST_DIR: $KNAPSACK_TEST_DIR
KNAPSACK_GENERATE_REPORT: $KNAPSACK_GENERATE_REPORT

View File

@ -16,13 +16,6 @@ services:
RAILS_DB_PASSWORD: ''
DATABASE_URL: "postgres://postgres@postgres:5432/canvas_test"
RANDOMIZE_SEQUENCES: 1
CI_NODE_TOTAL: $CI_NODE_TOTAL
CI_NODE_INDEX: $CI_NODE_INDEX
KNAPSACK_ENABLED: $KNAPSACK_ENABLED
KNAPSACK_TEST_FILE_PATTERN: $KNAPSACK_TEST_FILE_PATTERN
KNAPSACK_EXCLUDE_REGEX: $KNAPSACK_EXCLUDE_REGEX
KNAPSACK_TEST_DIR: $KNAPSACK_TEST_DIR
KNAPSACK_GENERATE_REPORT: $KNAPSACK_GENERATE_REPORT
RERUNS_RETRY: $RERUNS_RETRY
MAX_FAIL: $MAX_FAIL