Skip to content

Commit

Permalink
moved generating of c4gh key for dev envirnoment to compose file
Browse files Browse the repository at this point in the history
  • Loading branch information
pahatz committed Sep 6, 2023
1 parent c641035 commit 928eedf
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 7 deletions.
16 changes: 15 additions & 1 deletion sda-auth/dev-server/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,19 @@ services:
- CEGA_USERS_USER=dummy
ports:
- 8443:8443
keygen:
image: golang:alpine3.16
container_name: keygen
command:
- "/bin/sh"
- "-c"
- if [ ! -f "/out/c4gh_key.sec.pem" ]; then git --help >/dev/null 2>&1; [[ "$$?" != "0" ]] && apk add git;
[ ! -d "crypt4gh" ] && git clone https://github.com/neicnordic/crypt4gh.git;
cd crypt4gh;
[ ! -f "crypt4gh" ] && go build .;
./crypt4gh generate -n c4gh_key -p privatekeypass && mv *.pem /out/; fi
volumes:
- ../keys:/out
auth:
container_name: auth
build:
Expand All @@ -50,6 +63,8 @@ services:
condition: service_started
cega:
condition: service_started
keygen:
condition: service_completed_successfully
environment:
- ELIXIR_ID=XC56EL11xx
- ELIXIR_PROVIDER=http://oidc:9090
Expand All @@ -70,7 +85,6 @@ services:
volumes:
- ../keys:/keys
- ../:/sda-auth
- ./keys/c4gh_key.pub.pem:/c4gh_key.pub.pem
image: sda-auth
ports:
- 8080:8080
Expand Down
6 changes: 0 additions & 6 deletions sda-auth/dev-server/setup.sh

This file was deleted.

0 comments on commit 928eedf

Please sign in to comment.