Skip to content

Commit

Permalink
Merge pull request #558 from overture-stack/update_clients__score#214
Browse files Browse the repository at this point in the history
Bugfix: sing now computes it's parent directory correctly
  • Loading branch information
KevinFHartmann authored Dec 10, 2019
2 parents e12f7b5 + be2860d commit ec53a29
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 14 deletions.
2 changes: 0 additions & 2 deletions .env

This file was deleted.

3 changes: 1 addition & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@ FROM openjdk:11-jre-stretch as client

ENV SONG_CLIENT_HOME /song-client
ENV CLIENT_DIST_DIR /song-client-dist

ENV TARBALL $DCC_HOME/download.tar.gz
ENV PATH /usr/local/openjdk-11/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:$SONG_CLIENT_HOME/bin

COPY --from=builder /srv/song-client/target/song-client-*-dist.tar.gz /song-client.tar.gz

Expand Down
1 change: 1 addition & 0 deletions Dockerfile.dev
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ FROM openjdk:11-jre-stretch as client

ENV SONG_CLIENT_HOME /song-client
ENV CLIENT_DIST_DIR /song-client-dist
ENV PATH /usr/local/openjdk-11/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:$SONG_CLIENT_HOME/bin

COPY song-client/target/song-client-*-dist.tar.gz /song-client.tar.gz
RUN tar zxvf song-client.tar.gz -C /tmp \
Expand Down
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ LOG_DIRS := $(SCORE_SERVER_LOGS_DIR) $(SCORE_CLIENT_LOGS_DIR) $(SONG_SERVER_LOGS
DOCKER_COMPOSE_CMD := echo "*********** DEMO_MODE = $(DEMO_MODE) **************" \
&& echo "*********** FORCE = $(FORCE) **************" \
&& DOCKERFILE_NAME=$(DOCKERFILE_NAME) MY_UID=$(MY_UID) MY_GID=$(MY_GID) $(DOCKER_COMPOSE_EXE) -f $(ROOT_DIR)/docker-compose.yml
SONG_CLIENT_CMD := $(DOCKER_COMPOSE_CMD) run --rm -u $(THIS_USER) song-client bin/sing
SONG_CLIENT_CMD := $(DOCKER_COMPOSE_CMD) run --rm -u $(THIS_USER) song-client sing
SCORE_CLIENT_CMD := $(DOCKER_COMPOSE_CMD) run --rm -u $(THIS_USER) score-client bin/score-client
DC_UP_CMD := $(DOCKER_COMPOSE_CMD) up -d --build
MVN_CMD := $(MVN_EXE) -f $(ROOT_DIR)/pom.xml
Expand Down Expand Up @@ -238,8 +238,8 @@ get-analysis-id:
test-submit: start-song-server _ping_song_server
@echo $(YELLOW)$(INFO_HEADER) "Submitting payload /data/submit/exampleVariantCall.json" $(END)
@$(SONG_CLIENT_CMD) submit -f /data/submit/exampleVariantCall.json | tee $(SONG_CLIENT_SUBMIT_RESPONSE_FILE)
@cat $(SONG_CLIENT_SUBMIT_RESPONSE_FILE) | grep analysisId | sed 's/.*://' | sed 's/"\|,//g' > $(SONG_CLIENT_ANALYSIS_ID_FILE)
@echo $(YELLOW)$(INFO_HEADER) "Successfully submitted. Cached analysisId: " $$($(GET_ANALYSIS_ID_CMD)) $(END)
@cat $(SONG_CLIENT_SUBMIT_RESPONSE_FILE) | grep analysisId | sed -e 's#.*:[^"]*"\([^"]*\)".*#\1#' > $(SONG_CLIENT_ANALYSIS_ID_FILE)
@echo $(YELLOW)$(INFO_HEADER) "Successfully submitted. Cached analysisId: '"$$($(GET_ANALYSIS_ID_CMD))"'" $(END)

test-manifest: test-submit
@echo $(YELLOW)$(INFO_HEADER) "Creating manifest at /song-client/output" $(END)
Expand Down
2 changes: 2 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ services:
- "./docker/scratch/score-client-logs:/score-client/logs"
- "./docker/scratch/song-client-output:/song-client/output"
command: bin/score-client
user: "$MY_UID:$MY_GID"
song-db:
image: "postgres:9.6"
environment:
Expand Down Expand Up @@ -123,6 +124,7 @@ services:
- "./docker/scratch/song-client-logs:/song-client/logs"
- "./docker/scratch/song-client-output:/song-client/output"
command: bin/sing
user: "$MY_UID:$MY_GID"
song-server:
build:
context: ./
Expand Down
2 changes: 1 addition & 1 deletion docker/tools/song-client-demo
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ DOCKERFILE_NAME=Dockerfile \
MY_GID=$(id -g) \
docker-compose \
-f ${BASH_SCRIPT_DIR}/../../docker-compose.yml \
run --rm song-client bin/sing $@
run --rm song-client sing $@
2 changes: 1 addition & 1 deletion docker/tools/song-client-dev
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ DOCKERFILE_NAME=Dockerfile.dev \
MY_GID=$(id -g) \
docker-compose \
-f ${BASH_SCRIPT_DIR}/../..//docker-compose.yml \
run --rm song-client bin/sing $@
run --rm song-client sing $@
8 changes: 3 additions & 5 deletions song-client/src/main/bin/sing
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ elif [[ -n "$JAVA_HOME" ]] && [[ -x "$JAVA_HOME/bin/java" ]]; then
# echo Found Java in JAVA_HOME
_java="$JAVA_HOME/bin/java"
else
echo "Java not found. Sing requires JDK 1.8"
echo "Java not found. Sing requires Java 11."
exit 1
fi

Expand All @@ -42,10 +42,8 @@ if [[ "$_java" ]]; then
fi
fi

current_dir=$PWD
fn=$0
sing_home=$current_dir/`dirname $fn`/../

here=$(dirname $0)
sing_home=${here%/bin}
# -Dspring.config.location="$sing_home/conf/" \

java --illegal-access=deny \
Expand Down

0 comments on commit ec53a29

Please sign in to comment.