Commit 6224f02e authored by David Diederich's avatar David Diederich
Browse files

Merge branch 'ibm' into 'master'

add Ibm provider

See merge request !19
parents e6fb03bd 12e91a46
.ibm:
tags: ['docker-runner']
image: openshift/origin-cli
environment:
name: IBM
variables:
IBM_DEPLOY_DIR: ibm_deploy_dir
IBM_OPENSHIFT_PROJECT: og-cicd
before_script:
- mkdir -p "$IBM_DEPLOY_DIR"
- oc login $IBM_OPENSHIFT_URL -u apikey -p $IBM_OPENSHIFT_TOKEN
ibm-deploy:
extends: .ibm
stage: deploy
needs: ['compile-and-unit-test']
script:
- cp -v ${IBM_BUILD_SUBDIR}/target/*-spring-boot.jar "$IBM_DEPLOY_DIR"
- cd "$IBM_DEPLOY_DIR"
- oc project $IBM_OPENSHIFT_PROJECT
- oc get bc/$CI_PROJECT_NAME 2> /dev/null || oc new-build --name $CI_PROJECT_NAME --binary --strategy source --image-stream openshift/java:8
- oc start-build $CI_PROJECT_NAME --from-dir=. --follow
- oc get service $CI_PROJECT_NAME 2> /dev/null || oc new-app $CI_PROJECT_NAME
rules:
- if: $IBM_SKIP_DEPLOY == 'true'
when: never
- if: $IBM_BUILD_SUBDIR && $IBM == 'true' && $IBM_OPENSHIFT_URL && $IBM_OPENSHIFT_TOKEN
.ibm_variables:
variables:
# COMMON TEST
DOMAIN: $IBM_DOMAIN
ENTITLEMENTS_DOMAIN: $IBM_DOMAIN
DEFAULT_DATA_PARTITION_ID_TENANT1: opendes # must be opendes to work
DEFAULT_DATA_PARTITION_ID_TENANT2: tenant2
LEGAL_TAG: opendes-public-usa-dataset-1 # must exist in target instance
OTHER_RELEVANT_DATA_COUNTRIES: US
# Services
SEARCH_HOST: $IBM_SEARCH_HOST
STORAGE_HOST: $IBM_STORAGE_HOST
DELIVERY_HOST: $IBM_DELIVERY_HOST
# common security
KEYCLOAK_URL: $IBM_KEYCLOAK_URL
KEYCLOAK_REALM: OSDU
KEYCLOAK_CLIENT_ID: $IBM_KEYCLOAK_CLIENT_ID
KEYCLOAK_CLIENT_SECRET: $IBM_KEYCLOAK_CLIENT_SECRET
AUTH_USER_ACCESS: $IBM_AUTH_USER_ACCESS
AUTH_USER_ACCESS_PASSWORD: $IBM_AUTH_USER_ACCESS_PASSWORD
AUTH_USER_NO_ACCESS: $IBM_AUTH_USER_NO_ACCESS
AUTH_USER_NO_ACCESS_PASSWORD: $IBM_AUTH_USER_NO_ACCESS_PASSWORD
# SEARCH TEST
USER_EMAIL: $IBM_KEYCLOAK_USER_EMAIL
ELASTIC_HOST: $IBM_ELASTIC_HOST
ELASTIC_USER_NAME: $IBM_ELASTIC_USER_NAME
ELASTIC_PASSWORD: $IBM_ELASTIC_PASSWORD
ELASTIC_PORT: $IBM_ELASTIC_PORT
# Storage
PROJECT_ID: 1
DEPLOY_ENV: empty
TENANT_NAME: opendes
PUBSUB_TOKEN: token_not_implemented
STORAGE_URL: $IBM_STORAGE_HOST
LEGAL_URL: $IBM_LEGAL_HOST
ENTITLEMENT_URL: $IBM_ENTITLEMENT_URL
# Delivery
IBM_COS_ENDPOINT: $IBM_COS_ENDPOINT
IBM_COS_REGION: $IBM_COS_REGION
IBM_COS_ACCESS_KEY: $IBM_COS_ACCESS_KEY
IBM_COS_SECRET_KEY: $IBM_COS_SECRET_KEY
# Legal
HOST_URL: $IBM_LEGAL_HOST
MY_TENANT: $TENANT_NAME
MY_TENANT_PROJECT: OpenDES_Project
IBM_ENV_PREFIX: $IBM_ENV_PREFIX
IBM_LEGAL_MQ_CONNECTION: $IBM_LEGAL_MQ_CONNECTION
ibm-test:
stage: integration
needs: ["ibm-deploy"]
extends:
- .maven
- .ibm_variables
script:
- $MAVEN install -f ${IBM_INT_TEST_SUBDIR/ibm/core}/pom.xml
- $MAVEN clean test -q -f $IBM_INT_TEST_SUBDIR/pom.xml > test-results.log
- cat $IBM_INT_TEST_SUBDIR/target/surefire-reports/*.txt
artifacts:
when: always
paths:
- test-results.log
- $IBM_INT_TEST_SUBDIR/target/surefire-reports/TEST-*.xml
reports:
junit:
- $IBM_INT_TEST_SUBDIR/target/surefire-reports/TEST-*.xml
only:
variables:
- $IBM_INT_TEST_SUBDIR && $IBM == 'true'
except:
variables:
- $IBM_SKIP_TEST == 'true'
......@@ -4,6 +4,7 @@ include:
- local: 'scanners/gitlab-ultimate.yml'
- local: 'cloud-providers/aws.yml'
- local: 'cloud-providers/gcp.yml'
- local: 'cloud-providers/ibm.yml'
- local: 'scanners/fossa.yml'
- local: 'publishing/pages.yml'
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment