Commit 987d7042 authored by Kamil Trzciński's avatar Kamil Trzciński
Browse files

Initial commit

parents
stages:
- build
- deploy
variables:
# Configure these variables in Secure Variables:
# OPENSHIFT_SERVER: https://openshift.domain.com:8443
# OPENSHIFT_TOKEN: my.openshift.token
# OPENSHIFT_DOMAIN: routes.openshift.domain.com
before_script:
- oc login $OPENSHIFT_SERVER --token=$OPENSHIFT_TOKEN --insecure-skip-tls-verify
- oc status
review:
image: ayufan/openshift-cli
stage: deploy
script:
- oc get services $APP || oc new-app . --name=$APP --strategy=docker
- oc get routes $APP || oc expose service $APP --hostname=$APP_HOST
- oc start-build $APP --from-dir=. --wait
variables:
APP: review-$CI_BUILD_REF_NAME
APP_HOST: $CI_BUILD_REF_NAME.$OPENSHIFT_DOMAIN
environment:
name: review/$APP
url: http://$APP_HOST
FROM httpd:alpine
COPY ./public/ /usr/local/apache2/htdocs/
# This is example project presents how to use Review Apps with OpenShift
Hello World my app
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