Skip to content
Snippets Groups Projects
Commit 11111128 authored by Mikhail Piatliou (EPAM)'s avatar Mikhail Piatliou (EPAM) Committed by Oleksandr Kosse (EPAM)
Browse files

Migrate legal service from AppEngine to CloudRUN (GONRG-989)

parent 58f9ae48
No related branches found
No related tags found
No related merge requests found
......@@ -11,9 +11,10 @@ variables:
GCP_PROJECT: opendes-evt
GCP_TENANT_NAME: opendes-evt
OSDU_GCP_BUILD_SUBDIR: provider/legal-gcp
OSDU_GCP_INT_TEST_SUBDIR: testing/legal-test-gcp
OSDU_GCP_SERVICE: legal
OSDU_GCP_VENDOR: gcp
OSDU_GCP_APPLICATION_NAME: os-legal
OSDU_GCP_ENV_VARS: ENABLE_FULL_BUCKET_NAME=$ENABLE_FULL_BUCKET_NAME,PROJECT_ID=$OSDU_GCP_PROJECT,AUTHORIZE_API=$OSDU_GCP_AUTHORIZE_API,AUDIENCES=$GOOGLE_AUDIENCE,REDIS_GROUP_HOST=$REDIS_GROUP_HOST,REDIS_STORAGE_HOST=$REDIS_STORAGE_HOST,LEGAL_HOSTNAME=$OSDU_GCP_LEGAL_HOSTNAME --vpc-connector=$OSDU_GCP_VPC_CONNECTOR
IBM_BUILD_SUBDIR: provider/legal-ibm
IBM_INT_TEST_SUBDIR: testing/legal-test-ibm
......@@ -22,7 +23,6 @@ variables:
AZURE_BUILD_SUBDIR: provider/legal-azure
AZURE_TEST_SUBDIR: testing/legal-test-azure
include:
- project: "osdu/platform/ci-cd-pipelines"
file: "standard-setup.yml"
......@@ -47,7 +47,7 @@ include:
- project: 'osdu/platform/ci-cd-pipelines'
ref: "master"
file: 'cloud-providers/osdu-gcp.yml'
file: 'cloud-providers/osdu-gcp-cloudrun.yml'
- project: 'osdu/platform/ci-cd-pipelines'
ref: "master"
......
# Use the official AdoptOpenJDK for a base image.
# https://hub.docker.com/_/openjdk
FROM openjdk:8-slim
WORKDIR /app
ARG PROVIDER_NAME
ENV PROVIDER_NAME $PROVIDER_NAME
ARG PORT
ENV PORT $PORT
# Copy the jar to the production image from the builder stage.
COPY provider/legal-${PROVIDER_NAME}/target/legal-${PROVIDER_NAME}-*-spring-boot.jar legal-${PROVIDER_NAME}.jar
# Run the web service on container startup.
CMD java -Djava.security.egd=file:/dev/./urandom -Dserver.port=${PORT} -jar /app/legal-${PROVIDER_NAME}.jar
# Copyright 2020 Google LLC
# Copyright 2017-2019, Schlumberger
# Copyright 2020 EPAM
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
steps:
- name: 'gcr.io/cloud-builders/docker'
args: [
'build',
'--build-arg', 'PROVIDER_NAME=${_PROVIDER_NAME}',
'--build-arg', 'PORT=${_PORT}',
'-t', 'gcr.io/$PROJECT_ID/os-legal/legal-${_PROVIDER_NAME}:${_SHORT_SHA}',
'-t', 'gcr.io/$PROJECT_ID/os-legal/legal-${_PROVIDER_NAME}:latest',
'-f', 'provider/legal-${_PROVIDER_NAME}/cloudbuild/Dockerfile.cloudbuild',
'.'
]
images:
- 'gcr.io/$PROJECT_ID/os-legal/legal-${_PROVIDER_NAME}'
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment