You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airavata.apache.org by is...@apache.org on 2023/02/08 02:47:28 UTC
[airavata-custos] branch baremetal updated: upload dist folder for distribution creation
This is an automated email from the ASF dual-hosted git repository.
isjarana pushed a commit to branch baremetal
in repository https://gitbox.apache.org/repos/asf/airavata-custos.git
The following commit(s) were added to refs/heads/baremetal by this push:
new 7c8d2b55a upload dist folder for distribution creation
new 123449192 Merge pull request #343 from isururanawaka/baremetal
7c8d2b55a is described below
commit 7c8d2b55a4db64620435e31bd81f46ba99e7c86e
Author: Isuru Ranawaka <ir...@gmail.com>
AuthorDate: Tue Feb 7 21:46:14 2023 -0500
upload dist folder for distribution creation
---
.../src/main/dist/bin/custos-daemon.sh | 113 +++++++++++++++++++++
.../src/main/dist/bin/custos.sh | 71 +++++++++++++
.../src/main/dist/bin/setenv.sh | 46 +++++++++
.../src/main/dist/conf/application.properties | 90 ++++++++++++++++
.../src/main/dist/conf/bootstrap.properties | 26 +++++
.../dist/conf/keycloak-client-truststore.pkcs12 | Bin 0 -> 5709 bytes
.../src/main/dist/conf/log4j2.xml | 49 +++++++++
.../main/dist/conf/vault-client-truststore.pkcs12 | Bin 0 -> 5709 bytes
.../dist/custos-core-services-server-assembly.xml | 84 +++++++++++++++
.../src/main/dist/bin/custos-daemon.sh | 113 +++++++++++++++++++++
.../src/main/dist/bin/custos.sh | 71 +++++++++++++
.../src/main/dist/bin/setenv.sh | 46 +++++++++
.../src/main/dist/conf/application.properties | 37 +++++++
.../src/main/dist/conf/log4j2.xml | 49 +++++++++
...custos-integration-services-server-assembly.xml | 84 +++++++++++++++
15 files changed, 879 insertions(+)
diff --git a/custos-services/custos-core-services-server/src/main/dist/bin/custos-daemon.sh b/custos-services/custos-core-services-server/src/main/dist/bin/custos-daemon.sh
new file mode 100644
index 000000000..a7233c051
--- /dev/null
+++ b/custos-services/custos-core-services-server/src/main/dist/bin/custos-daemon.sh
@@ -0,0 +1,113 @@
+#!/usr/bin/env bash
+
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you 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.
+
+. `dirname $0`/setenv.sh
+# Capture user's working dir before changing directory
+CWD="$PWD"
+cd ${AIRAVATA_HOME}/bin
+LOGO_FILE="logo.txt"
+
+JAVA_OPTS="-Dspring.config.location=${AIRAVATA_HOME}/conf/ -Dairavata.home=${AIRAVATA_HOME} -Dlog4j.configurationFile=file:${AIRAVATA_HOME}/conf/log4j2.xml"
+AIRAVATA_COMMAND=""
+EXTRA_ARGS=""
+SERVERS=""
+LOGO=true
+IS_SUBSET=false
+SUBSET=""
+DEFAULT_LOG_FILE="${AIRAVATA_HOME}/logs/custos-daemon.out"
+LOG_FILE=$DEFAULT_LOG_FILE
+
+SERVICE_NAME="Custos"
+PID_PATH_NAME="${AIRAVATA_HOME}/bin/service-pid"
+
+case $1 in
+ start)
+ echo "Starting $SERVICE_NAME ..."
+ if [ ! -f $PID_PATH_NAME ]; then
+ nohup java ${JAVA_OPTS} -classpath "${AIRAVATA_CLASSPATH}" \
+ org.apache.custos.core.services.api.CoreServicesServer ${AIRAVATA_COMMAND} $* > $LOG_FILE 2>&1 &
+ echo $! > $PID_PATH_NAME
+ echo "$SERVICE_NAME started ..."
+ else
+ echo "$SERVICE_NAME is already running ..."
+ fi
+ ;;
+ stop)
+ if [ -f $PID_PATH_NAME ]; then
+ PID=$(cat $PID_PATH_NAME);
+ echo "$SERVICE_NAME stoping ..."
+ kill $PID;
+ RETRY=0
+ while kill -0 $PID 2> /dev/null; do
+ echo "Waiting for the process $PID to be stopped"
+ RETRY=`expr ${RETRY} + 1`
+ if [ "${RETRY}" -gt "20" ]
+ then
+ echo "Forcefully killing the process as it is not responding ..."
+ kill -9 $PID
+ fi
+ sleep 1
+ done
+ echo "$SERVICE_NAME stopped ..."
+ rm $PID_PATH_NAME
+ else
+ echo "$SERVICE_NAME is not running ..."
+ fi
+ ;;
+ restart)
+ if [ -f $PID_PATH_NAME ]; then
+ PID=$(cat $PID_PATH_NAME);
+ echo "$SERVICE_NAME stopping ...";
+ kill $PID;
+ RETRY=0
+ while kill -0 $PID 2> /dev/null; do
+ echo "Waiting for the process $PID to be stopped"
+ RETRY=`expr ${RETRY} + 1`
+ if [ "${RETRY}" -gt "20" ]
+ then
+ echo "Forcefully killing the process as it is not responding ..."
+ kill -9 $PID
+ fi
+ sleep 1
+ done
+ echo "$SERVICE_NAME stopped ...";
+ rm $PID_PATH_NAME
+ echo "$SERVICE_NAME starting ..."
+ nohup java ${JAVA_OPTS} -classpath "${AIRAVATA_CLASSPATH}" \
+ org.apache.custos.core.services.api.CoreServicesServer ${AIRAVATA_COMMAND} $* > $LOG_FILE 2>&1 &
+ echo $! > $PID_PATH_NAME
+ echo "$SERVICE_NAME started ..."
+ else
+ echo "$SERVICE_NAME is not running ..."
+ fi
+ ;;
+ -h)
+ echo "Usage: custos-daemon.sh"
+
+ echo "command options:"
+ echo " start Start server in daemon mode"
+ echo " stop Stop server running in daemon mode"
+ echo " restart Restart server in daemon mode"
+ echo " -log <LOG_FILE> Where to redirect stdout/stderr (defaults to $DEFAULT_LOG_FILE)"
+ echo " -h Display this help and exit"
+ shift
+ exit 0
+ ;;
+esac
+
diff --git a/custos-services/custos-core-services-server/src/main/dist/bin/custos.sh b/custos-services/custos-core-services-server/src/main/dist/bin/custos.sh
new file mode 100644
index 000000000..2c780edee
--- /dev/null
+++ b/custos-services/custos-core-services-server/src/main/dist/bin/custos.sh
@@ -0,0 +1,71 @@
+#!/usr/bin/env bash
+
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you 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.
+
+. `dirname $0`/setenv.sh
+# Capture user's working dir before changing directory
+CWD="$PWD"
+cd ${AIRAVATA_HOME}/bin
+LOGO_FILE="logo.txt"
+
+JAVA_OPTS="-Dspring.config.location=${AIRAVATA_HOME}/conf/ -Dairavata.home=${AIRAVATA_HOME} -Dlog4j.configurationFile=file:${AIRAVATA_HOME}/conf/log4j2.xml"
+AIRAVATA_COMMAND=""
+EXTRA_ARGS=""
+SERVERS=""
+IS_SUBSET=false
+SUBSET=""
+DEFAULT_LOG_FILE="${AIRAVATA_HOME}/logs/console.out"
+LOG_FILE=$DEFAULT_LOG_FILE
+
+# parse command arguments
+for var in "$@"
+do
+ case ${var} in
+ -xdebug)
+ AIRAVATA_COMMAND="${AIRAVATA_COMMAND}"
+ JAVA_OPTS="$JAVA_OPTS -Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,server=y,address=*:8000"
+ shift
+ ;;
+ -log)
+ shift
+ LOG_FILE="$1"
+ shift
+ # If relative path, expand to absolute path using the user's $CWD
+ if [ -z "`echo "$LOG_FILE" | egrep "^/"`" ]; then
+ LOG_FILE="${CWD}/${LOG_FILE}"
+ fi
+ ;;
+ -h)
+ echo "Usage: custos.sh"
+
+ echo "command options:"
+ echo " -xdebug Start DRMS Server under JPDA debugger"
+ echo " -h Display this help and exit"
+ shift
+ exit 0
+ ;;
+ *)
+ EXTRA_ARGS="${EXTRA_ARGS} ${var}"
+ shift
+ ;;
+ esac
+done
+
+java ${JAVA_OPTS} -classpath "${AIRAVATA_CLASSPATH}" \
+ org.apache.custos.core.services.api.CoreServicesServer ${AIRAVATA_COMMAND} $*
+
diff --git a/custos-services/custos-core-services-server/src/main/dist/bin/setenv.sh b/custos-services/custos-core-services-server/src/main/dist/bin/setenv.sh
new file mode 100644
index 000000000..9e894e1db
--- /dev/null
+++ b/custos-services/custos-core-services-server/src/main/dist/bin/setenv.sh
@@ -0,0 +1,46 @@
+#!/bin/sh
+
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you 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.
+
+# resolve links - $0 may be a softlink
+PRG="$0"
+
+while [ -h "$PRG" ]; do
+ ls=`ls -ld "$PRG"`
+ link=`expr "$ls" : '.*-> \(.*\)$'`
+ if expr "$link" : '.*/.*' > /dev/null; then
+ PRG="$link"
+ else
+ PRG=`dirname "$PRG"`/"$link"
+ fi
+done
+
+PRGDIR=`dirname "$PRG"`
+
+# Only set AIRAVATA_HOME if not already set
+[ -z "$AIRAVATA_HOME" ] && AIRAVATA_HOME=`cd "$PRGDIR/.." ; pwd`
+
+AIRAVATA_CLASSPATH=""
+
+for f in "$AIRAVATA_HOME"/lib/*.jar
+do
+ AIRAVATA_CLASSPATH="$AIRAVATA_CLASSPATH":$f
+done
+
+export AIRAVATA_HOME
+export AIRAVATA_CLASSPATH
diff --git a/custos-services/custos-core-services-server/src/main/dist/conf/application.properties b/custos-services/custos-core-services-server/src/main/dist/conf/application.properties
new file mode 100644
index 000000000..d70053767
--- /dev/null
+++ b/custos-services/custos-core-services-server/src/main/dist/conf/application.properties
@@ -0,0 +1,90 @@
+##
+## Licensed to the Apache Software Foundation (ASF) under one
+## or more contributor license agreements. See the NOTICE file
+## distributed with this work for additional information
+## regarding copyright ownership. The ASF licenses this file
+## to you 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.
+##
+#
+#grpc.port=7000
+#server.port=8080
+###spring.zipkin.baseUrl=http://149.165.169.49:9411/
+#spring.application.name=custos-core-services-server
+###spring.sleuth.sampler.probability=1
+#spring.main.allow-bean-definition-overriding=true
+#management.security.enabled=false
+#management.endpoints.web.exposure.include=*
+#management.endpoint.metrics.enabled=true
+#spring.jmx.enabled=true
+#
+#spring.datasource.url = jdbc:mysql://@mysql.host@:3306/core-services-db?useSSL=false&serverTimezone=UTC&useLegacyDatetimeCode=false&createDatabaseIfNotExist=true
+#spring.datasource.username = @spring.datasource.username@
+#spring.datasource.password = @spring.datasource.password@
+#
+#
+### Hibernate Properties
+## The SQL dialect makes Hibernate generate better SQL for the chosen database
+#spring.jpa.properties.hibernate.dialect = org.hibernate.dialect.MySQL5InnoDBDialect
+#spring.jpa.properties.hibernate.enable_lazy_load_no_trans=true
+## Hibernate ddl auto (create, create-drop, validate, update)
+#spring.jpa.hibernate.ddl-auto = update
+#spring.profiles.active=@spring.profiles.active@
+#logging.level.root=INFO
+#
+#
+#ciLogon.admin.client.id=${cilogon.production.id}
+#ciLogon.admin.client.secret=${cilogon.production.sec}
+#ciLogon.admin.auth.endpoint=https://test.cilogon.org/oauth2/oidc-cm
+#
+#
+#iam.server.client.id=admin-cli
+#iam.server.truststore.path=/home/ubuntu/keystore/keycloak-client-truststore.pkcs12
+#iam.server.truststore.password=keycloak
+#iam.server.url=https://keycloak.custos.scigap.org:31000/auth/
+#iam.server.admin.username=${iam.dev.username}
+#iam.server.admin.password=${iam.dev.password}
+#iam.server.super.admin.realm.id=master
+#iam.federated.cilogon.authorization.endpoint=https://cilogon.org/authorize
+#iam.federated.cilogon.token.endpoint=https://cilogon.org/oauth2/token
+#iam.federated.cilogon.token.userinfo.endpoint=https://cilogon.org/oauth2/userinfo
+#iam.federated.cilogon.issuer=https://cilogon.org
+#iam.federated.cilogon.jwksUri=https://cilogon.org/oauth2/certs
+#introspection.endpoint=https://custos.scigap.org:32036/identity-management/v1.0.0/token/introspect
+#issuer=https://custos.scigap.org/
+#authorization.endpoint=https://custos.scigap.org/apiserver/identity-management/v1.0.0/authorize
+#token.endpoint=https://custos.scigap.org/apiserver/identity-management/v1.0.0/token
+#end.session.endpoint=https://custos.scigap.org/apiserver/identity-management/v1.0.0/logout
+#user.info.endpoint=https://custos.scigap.org/apiserver/user-management/v1.0.0/userinfo
+#jwks_uri=https://custos.scigap.org/apiserver/identity-management/v1.0.0/certs
+#registration.endpoint=https://custos.scigap.org/apiserver/tenant-management/v1.0.0/oauth2/tenant
+#cluster.management.core.service.dns.name=cluster-management-core-service.keycloak.svc.cluster.local
+#cluster.management.core.service.port=7000
+#
+#
+#custos.identity.auth.cache.enabled=true
+#custos.identity.auth.cache.size=1024
+#
+#
+#
+#core.messaging.service.broker.url=custos07.sciencegateways.iu.edu:9092
+#core.messaging.service.publisher.id=custosEventPublisher
+#mail.smtp.auth=true
+#mail.smtp.starttls.enable=true
+#mail.smtp.host=smtp.gmail.com
+#mail.smtp.port=587
+#mail.smtp.ssl.trust=smtp.gmail.com
+#mail.sender.username=custosemailagent@gmail.com
+#mail.sender.password=${custos.email.password}
+#user.profile.core.service.dns.name=user-profile-core-service.custos.svc.cluster.local
+#user.profile.core.service.port=7000
diff --git a/custos-services/custos-core-services-server/src/main/dist/conf/bootstrap.properties b/custos-services/custos-core-services-server/src/main/dist/conf/bootstrap.properties
new file mode 100644
index 000000000..69c021b82
--- /dev/null
+++ b/custos-services/custos-core-services-server/src/main/dist/conf/bootstrap.properties
@@ -0,0 +1,26 @@
+##
+## Licensed to the Apache Software Foundation (ASF) under one
+## or more contributor license agreements. See the NOTICE file
+## distributed with this work for additional information
+## regarding copyright ownership. The ASF licenses this file
+## to you 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
+#
+#spring.cloud.vault.token=${vault.token}
+#spring.cloud.vault.scheme=${vault.scheme}
+#spring.cloud.vault.host=${vault.host}
+#spring.cloud.vault.port=${vault.port}
+#spring.cloud.vault.uri=${vault.uri}
+#spring.cloud.vault.authentication=token
+#spring.cloud.vault.ssl.trust-store=file:home/ubuntu/vault-client-truststore.pkcs12
+#spring.cloud.vault.ssl.trust-store-password=vaultpass
\ No newline at end of file
diff --git a/custos-services/custos-core-services-server/src/main/dist/conf/keycloak-client-truststore.pkcs12 b/custos-services/custos-core-services-server/src/main/dist/conf/keycloak-client-truststore.pkcs12
new file mode 100644
index 000000000..d36c2ce3f
Binary files /dev/null and b/custos-services/custos-core-services-server/src/main/dist/conf/keycloak-client-truststore.pkcs12 differ
diff --git a/custos-services/custos-core-services-server/src/main/dist/conf/log4j2.xml b/custos-services/custos-core-services-server/src/main/dist/conf/log4j2.xml
new file mode 100644
index 000000000..0c31d154d
--- /dev/null
+++ b/custos-services/custos-core-services-server/src/main/dist/conf/log4j2.xml
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you 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.
+
+-->
+<Configuration status="WARN">
+
+ <Appenders>
+ <Console name="Console" target="SYSTEM_OUT">
+ <PatternLayout pattern="%d [%t] %-5p %c{30} %X - %m%n"/>
+ </Console>
+ <RollingFile name="RollingFileAppender" fileName="../logs/airavata.log"
+ filePattern="logs/${date:yyyy-MM}/custos-log-%d{MM-dd-yyyy}-%i.log.gz">
+ <PatternLayout>
+ <Pattern>%d [%t] %-5p %c{30} %X - %m%n</Pattern>
+ </PatternLayout>
+ <Policies>
+ <OnStartupTriggeringPolicy />
+ <TimeBasedTriggeringPolicy />
+ <SizeBasedTriggeringPolicy size="50 MB" />
+ </Policies>
+ <DefaultRolloverStrategy max="20" />
+ </RollingFile>
+ </Appenders>
+ <Loggers>
+ <logger name="io.grpc.internal" level="OFF"/>
+ <Root level="INFO">
+ <AppenderRef ref="Console"/>
+ <AppenderRef ref="RollingFileAppender"/>
+ </Root>
+ </Loggers>
+</Configuration>
\ No newline at end of file
diff --git a/custos-services/custos-core-services-server/src/main/dist/conf/vault-client-truststore.pkcs12 b/custos-services/custos-core-services-server/src/main/dist/conf/vault-client-truststore.pkcs12
new file mode 100644
index 000000000..770aadb29
Binary files /dev/null and b/custos-services/custos-core-services-server/src/main/dist/conf/vault-client-truststore.pkcs12 differ
diff --git a/custos-services/custos-core-services-server/src/main/dist/custos-core-services-server-assembly.xml b/custos-services/custos-core-services-server/src/main/dist/custos-core-services-server-assembly.xml
new file mode 100644
index 000000000..a6048b1e4
--- /dev/null
+++ b/custos-services/custos-core-services-server/src/main/dist/custos-core-services-server-assembly.xml
@@ -0,0 +1,84 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you 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.
+-->
+<!DOCTYPE assembly [
+ <!ELEMENT assembly (id|includeBaseDirectory|baseDirectory|formats|fileSets|dependencySets)*>
+ <!ELEMENT id (#PCDATA)>
+ <!ELEMENT includeBaseDirectory (#PCDATA)>
+ <!ELEMENT baseDirectory (#PCDATA)>
+ <!ELEMENT formats (format)*>
+ <!ELEMENT format (#PCDATA)>
+ <!ELEMENT fileSets (fileSet)*>
+ <!ELEMENT fileSet (directory|outputDirectory|fileMode|includes)*>
+ <!ELEMENT directory (#PCDATA)>
+ <!ELEMENT outputDirectory (#PCDATA)>
+ <!ELEMENT includes (include)*>
+ <!ELEMENT include (#PCDATA)>
+ <!ELEMENT dependencySets (dependencySet)*>
+ <!ELEMENT dependencySet (outputDirectory|outputFileNameMapping|includes)*>
+ ]>
+<assembly>
+
+ <id>bin</id>
+ <includeBaseDirectory>true</includeBaseDirectory>
+ <baseDirectory>Custos-Core-Services-Server-${project.version}</baseDirectory>
+ <formats>
+ <format>tar.gz</format>
+ <format>zip</format>
+ </formats>
+
+ <fileSets>
+ <fileSet>
+ <directory>src/main/dist/bin</directory>
+ <outputDirectory>bin</outputDirectory>
+ <fileMode>777</fileMode>
+ <includes>
+ <include>*.sh</include>
+ </includes>
+ </fileSet>
+ <fileSet>
+ <directory>src/main/dist/conf</directory>
+ <outputDirectory>conf</outputDirectory>
+ <includes>
+ <include>*</include>
+ </includes>
+ </fileSet>
+ <fileSet>
+ <directory>./</directory>
+ <outputDirectory>logs</outputDirectory>
+ <excludes>
+ <exclude>*/**</exclude>
+ </excludes>
+ </fileSet>
+ <fileSet>
+ <directory>target</directory>
+ <outputDirectory>lib</outputDirectory>
+ <includes>
+ <include>*.jar</include>
+ </includes>
+ </fileSet>
+ </fileSets>
+
+ <dependencySets>
+ <dependencySet>
+ <useProjectArtifact>false</useProjectArtifact>
+ <outputDirectory>lib</outputDirectory>
+ <includes>
+ <include>*</include>
+ </includes>
+ </dependencySet>
+ </dependencySets>
+</assembly>
\ No newline at end of file
diff --git a/custos-services/custos-integration-services-server/src/main/dist/bin/custos-daemon.sh b/custos-services/custos-integration-services-server/src/main/dist/bin/custos-daemon.sh
new file mode 100644
index 000000000..16657b16b
--- /dev/null
+++ b/custos-services/custos-integration-services-server/src/main/dist/bin/custos-daemon.sh
@@ -0,0 +1,113 @@
+#!/usr/bin/env bash
+
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you 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.
+
+. `dirname $0`/setenv.sh
+# Capture user's working dir before changing directory
+CWD="$PWD"
+cd ${AIRAVATA_HOME}/bin
+LOGO_FILE="logo.txt"
+
+JAVA_OPTS="-Dspring.config.location=${AIRAVATA_HOME}/conf/ -Dairavata.home=${AIRAVATA_HOME} -Dlog4j.configurationFile=file:${AIRAVATA_HOME}/conf/log4j2.xml"
+AIRAVATA_COMMAND=""
+EXTRA_ARGS=""
+SERVERS=""
+LOGO=true
+IS_SUBSET=false
+SUBSET=""
+DEFAULT_LOG_FILE="${AIRAVATA_HOME}/logs/custos-daemon.out"
+LOG_FILE=$DEFAULT_LOG_FILE
+
+SERVICE_NAME="DRMS"
+PID_PATH_NAME="${AIRAVATA_HOME}/bin/service-pid"
+
+case $1 in
+ start)
+ echo "Starting $SERVICE_NAME ..."
+ if [ ! -f $PID_PATH_NAME ]; then
+ nohup java ${JAVA_OPTS} -classpath "${AIRAVATA_CLASSPATH}" \
+ org.apache.custos.integration.services.api.IntegrationServicesServer ${AIRAVATA_COMMAND} $* > $LOG_FILE 2>&1 &
+ echo $! > $PID_PATH_NAME
+ echo "$SERVICE_NAME started ..."
+ else
+ echo "$SERVICE_NAME is already running ..."
+ fi
+ ;;
+ stop)
+ if [ -f $PID_PATH_NAME ]; then
+ PID=$(cat $PID_PATH_NAME);
+ echo "$SERVICE_NAME stoping ..."
+ kill $PID;
+ RETRY=0
+ while kill -0 $PID 2> /dev/null; do
+ echo "Waiting for the process $PID to be stopped"
+ RETRY=`expr ${RETRY} + 1`
+ if [ "${RETRY}" -gt "20" ]
+ then
+ echo "Forcefully killing the process as it is not responding ..."
+ kill -9 $PID
+ fi
+ sleep 1
+ done
+ echo "$SERVICE_NAME stopped ..."
+ rm $PID_PATH_NAME
+ else
+ echo "$SERVICE_NAME is not running ..."
+ fi
+ ;;
+ restart)
+ if [ -f $PID_PATH_NAME ]; then
+ PID=$(cat $PID_PATH_NAME);
+ echo "$SERVICE_NAME stopping ...";
+ kill $PID;
+ RETRY=0
+ while kill -0 $PID 2> /dev/null; do
+ echo "Waiting for the process $PID to be stopped"
+ RETRY=`expr ${RETRY} + 1`
+ if [ "${RETRY}" -gt "20" ]
+ then
+ echo "Forcefully killing the process as it is not responding ..."
+ kill -9 $PID
+ fi
+ sleep 1
+ done
+ echo "$SERVICE_NAME stopped ...";
+ rm $PID_PATH_NAME
+ echo "$SERVICE_NAME starting ..."
+ nohup java ${JAVA_OPTS} -classpath "${AIRAVATA_CLASSPATH}" \
+ org.apache.custos.integration.services.api.IntegrationServicesServer ${AIRAVATA_COMMAND} $* > $LOG_FILE 2>&1 &
+ echo $! > $PID_PATH_NAME
+ echo "$SERVICE_NAME started ..."
+ else
+ echo "$SERVICE_NAME is not running ..."
+ fi
+ ;;
+ -h)
+ echo "Usage: orch-api-server-daemon.sh"
+
+ echo "command options:"
+ echo " start Start server in daemon mode"
+ echo " stop Stop server running in daemon mode"
+ echo " restart Restart server in daemon mode"
+ echo " -log <LOG_FILE> Where to redirect stdout/stderr (defaults to $DEFAULT_LOG_FILE)"
+ echo " -h Display this help and exit"
+ shift
+ exit 0
+ ;;
+esac
+
diff --git a/custos-services/custos-integration-services-server/src/main/dist/bin/custos.sh b/custos-services/custos-integration-services-server/src/main/dist/bin/custos.sh
new file mode 100644
index 000000000..04fc57a6f
--- /dev/null
+++ b/custos-services/custos-integration-services-server/src/main/dist/bin/custos.sh
@@ -0,0 +1,71 @@
+#!/usr/bin/env bash
+
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you 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.
+
+. `dirname $0`/setenv.sh
+# Capture user's working dir before changing directory
+CWD="$PWD"
+cd ${AIRAVATA_HOME}/bin
+LOGO_FILE="logo.txt"
+
+JAVA_OPTS="-Dspring.config.location=${AIRAVATA_HOME}/conf/ -Dairavata.home=${AIRAVATA_HOME} -Dlog4j.configurationFile=file:${AIRAVATA_HOME}/conf/log4j2.xml"
+AIRAVATA_COMMAND=""
+EXTRA_ARGS=""
+SERVERS=""
+IS_SUBSET=false
+SUBSET=""
+DEFAULT_LOG_FILE="${AIRAVATA_HOME}/logs/console.out"
+LOG_FILE=$DEFAULT_LOG_FILE
+
+# parse command arguments
+for var in "$@"
+do
+ case ${var} in
+ -xdebug)
+ AIRAVATA_COMMAND="${AIRAVATA_COMMAND}"
+ JAVA_OPTS="$JAVA_OPTS -Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,server=y,address=*:8000"
+ shift
+ ;;
+ -log)
+ shift
+ LOG_FILE="$1"
+ shift
+ # If relative path, expand to absolute path using the user's $CWD
+ if [ -z "`echo "$LOG_FILE" | egrep "^/"`" ]; then
+ LOG_FILE="${CWD}/${LOG_FILE}"
+ fi
+ ;;
+ -h)
+ echo "Usage: drms.sh"
+
+ echo "command options:"
+ echo " -xdebug Start DRMS Server under JPDA debugger"
+ echo " -h Display this help and exit"
+ shift
+ exit 0
+ ;;
+ *)
+ EXTRA_ARGS="${EXTRA_ARGS} ${var}"
+ shift
+ ;;
+ esac
+done
+
+java ${JAVA_OPTS} -classpath "${AIRAVATA_CLASSPATH}" \
+ org.apache.custos.integration.services.api.IntegrationServicesServer ${AIRAVATA_COMMAND} $*
+
diff --git a/custos-services/custos-integration-services-server/src/main/dist/bin/setenv.sh b/custos-services/custos-integration-services-server/src/main/dist/bin/setenv.sh
new file mode 100644
index 000000000..9e894e1db
--- /dev/null
+++ b/custos-services/custos-integration-services-server/src/main/dist/bin/setenv.sh
@@ -0,0 +1,46 @@
+#!/bin/sh
+
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you 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.
+
+# resolve links - $0 may be a softlink
+PRG="$0"
+
+while [ -h "$PRG" ]; do
+ ls=`ls -ld "$PRG"`
+ link=`expr "$ls" : '.*-> \(.*\)$'`
+ if expr "$link" : '.*/.*' > /dev/null; then
+ PRG="$link"
+ else
+ PRG=`dirname "$PRG"`/"$link"
+ fi
+done
+
+PRGDIR=`dirname "$PRG"`
+
+# Only set AIRAVATA_HOME if not already set
+[ -z "$AIRAVATA_HOME" ] && AIRAVATA_HOME=`cd "$PRGDIR/.." ; pwd`
+
+AIRAVATA_CLASSPATH=""
+
+for f in "$AIRAVATA_HOME"/lib/*.jar
+do
+ AIRAVATA_CLASSPATH="$AIRAVATA_CLASSPATH":$f
+done
+
+export AIRAVATA_HOME
+export AIRAVATA_CLASSPATH
diff --git a/custos-services/custos-integration-services-server/src/main/dist/conf/application.properties b/custos-services/custos-integration-services-server/src/main/dist/conf/application.properties
new file mode 100644
index 000000000..05e8fc2e6
--- /dev/null
+++ b/custos-services/custos-integration-services-server/src/main/dist/conf/application.properties
@@ -0,0 +1,37 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you 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.
+#
+
+grpc.port=7000
+server.port=8080
+##spring.zipkin.baseUrl=http://149.165.169.49:9411/
+spring.application.name=custos-integrations-services-server
+##spring.sleuth.sampler.probability=1
+spring.main.allow-bean-definition-overriding=true
+management.security.enabled=false
+management.endpoints.web.exposure.include=*
+management.endpoint.metrics.enabled=true
+spring.jmx.enabled=true
+
+spring.profiles.active=dev
+logging.level.root=INFO
+
+core.services.server.port=7000
+core.services.server.hostname=localhost
+iam.server.url=https://keycloak.custos.scigap.org:31000/auth/
+tenant.base.uri=https://service.staging.usecustos.org/apiserver/tenant-management/v1.0.0/oauth2/tenant
diff --git a/custos-services/custos-integration-services-server/src/main/dist/conf/log4j2.xml b/custos-services/custos-integration-services-server/src/main/dist/conf/log4j2.xml
new file mode 100644
index 000000000..0c31d154d
--- /dev/null
+++ b/custos-services/custos-integration-services-server/src/main/dist/conf/log4j2.xml
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you 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.
+
+-->
+<Configuration status="WARN">
+
+ <Appenders>
+ <Console name="Console" target="SYSTEM_OUT">
+ <PatternLayout pattern="%d [%t] %-5p %c{30} %X - %m%n"/>
+ </Console>
+ <RollingFile name="RollingFileAppender" fileName="../logs/airavata.log"
+ filePattern="logs/${date:yyyy-MM}/custos-log-%d{MM-dd-yyyy}-%i.log.gz">
+ <PatternLayout>
+ <Pattern>%d [%t] %-5p %c{30} %X - %m%n</Pattern>
+ </PatternLayout>
+ <Policies>
+ <OnStartupTriggeringPolicy />
+ <TimeBasedTriggeringPolicy />
+ <SizeBasedTriggeringPolicy size="50 MB" />
+ </Policies>
+ <DefaultRolloverStrategy max="20" />
+ </RollingFile>
+ </Appenders>
+ <Loggers>
+ <logger name="io.grpc.internal" level="OFF"/>
+ <Root level="INFO">
+ <AppenderRef ref="Console"/>
+ <AppenderRef ref="RollingFileAppender"/>
+ </Root>
+ </Loggers>
+</Configuration>
\ No newline at end of file
diff --git a/custos-services/custos-integration-services-server/src/main/dist/custos-integration-services-server-assembly.xml b/custos-services/custos-integration-services-server/src/main/dist/custos-integration-services-server-assembly.xml
new file mode 100644
index 000000000..2bc7c1d7a
--- /dev/null
+++ b/custos-services/custos-integration-services-server/src/main/dist/custos-integration-services-server-assembly.xml
@@ -0,0 +1,84 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you 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.
+-->
+<!DOCTYPE assembly [
+ <!ELEMENT assembly (id|includeBaseDirectory|baseDirectory|formats|fileSets|dependencySets)*>
+ <!ELEMENT id (#PCDATA)>
+ <!ELEMENT includeBaseDirectory (#PCDATA)>
+ <!ELEMENT baseDirectory (#PCDATA)>
+ <!ELEMENT formats (format)*>
+ <!ELEMENT format (#PCDATA)>
+ <!ELEMENT fileSets (fileSet)*>
+ <!ELEMENT fileSet (directory|outputDirectory|fileMode|includes)*>
+ <!ELEMENT directory (#PCDATA)>
+ <!ELEMENT outputDirectory (#PCDATA)>
+ <!ELEMENT includes (include)*>
+ <!ELEMENT include (#PCDATA)>
+ <!ELEMENT dependencySets (dependencySet)*>
+ <!ELEMENT dependencySet (outputDirectory|outputFileNameMapping|includes)*>
+ ]>
+<assembly>
+
+ <id>bin</id>
+ <includeBaseDirectory>true</includeBaseDirectory>
+ <baseDirectory>Custos-Integration-Services-Server-${project.version}</baseDirectory>
+ <formats>
+ <format>tar.gz</format>
+ <format>zip</format>
+ </formats>
+
+ <fileSets>
+ <fileSet>
+ <directory>src/main/dist/bin</directory>
+ <outputDirectory>bin</outputDirectory>
+ <fileMode>777</fileMode>
+ <includes>
+ <include>*.sh</include>
+ </includes>
+ </fileSet>
+ <fileSet>
+ <directory>src/main/dist/conf</directory>
+ <outputDirectory>conf</outputDirectory>
+ <includes>
+ <include>*</include>
+ </includes>
+ </fileSet>
+ <fileSet>
+ <directory>./</directory>
+ <outputDirectory>logs</outputDirectory>
+ <excludes>
+ <exclude>*/**</exclude>
+ </excludes>
+ </fileSet>
+ <fileSet>
+ <directory>target</directory>
+ <outputDirectory>lib</outputDirectory>
+ <includes>
+ <include>*.jar</include>
+ </includes>
+ </fileSet>
+ </fileSets>
+
+ <dependencySets>
+ <dependencySet>
+ <useProjectArtifact>false</useProjectArtifact>
+ <outputDirectory>lib</outputDirectory>
+ <includes>
+ <include>*</include>
+ </includes>
+ </dependencySet>
+ </dependencySets>
+</assembly>
\ No newline at end of file