Improved script for user
This commit is contained in:
parent
2bab2edf43
commit
a3f9dc64b7
|
@ -286,9 +286,8 @@ It is not recommended to use this script in production!
|
|||
|
||||
### Basic Auth
|
||||
|
||||
Some services we use authfication to protect the data. For example for local data managemnt like the blaze.
|
||||
use add_user.sh
|
||||
|
||||
The /auth direcotry contians for each project a file with user and password combination. If it is not present please create a file with just the project name. To add a combination use [htpasswdgenerator](https://htpasswdgenerator.de/) or use htpasswd on your maschine.
|
||||
|
||||
### HTTPS Access
|
||||
|
||||
|
|
|
@ -9,10 +9,9 @@ services:
|
|||
- --entrypoints.web.address=:80
|
||||
- --entrypoints.websecure.address=:443
|
||||
- --providers.docker=true
|
||||
- --providers.file.directory=/configuration/
|
||||
- --providers.file.watch=true
|
||||
- --entrypoints.web.http.redirections.entrypoint.to=websecure
|
||||
- --entrypoints.web.http.redirections.entrypoint.scheme=https
|
||||
- --providers.file.watch=true
|
||||
ports:
|
||||
- 80:80
|
||||
- 443:443
|
||||
|
@ -48,13 +47,14 @@ services:
|
|||
- "blaze-data:/app/data"
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
- "traefik.http.middlewares.test-auth.basicauth.usersfile=/auth/dktk"
|
||||
- "traefik.http.middlewares.test-auth.basicauth.users=${bc_auth_users}"
|
||||
- "traefik.http.routers.blaze_dktk.rule=PathPrefix(`/dktk-localdatamanagement`)"
|
||||
- "traefik.http.middlewares.dktk_b_strip.stripprefix.prefixes=/dktk-localdatamanagement"
|
||||
- "traefik.http.services.blaze_dktk.loadbalancer.server.port=8080"
|
||||
- "traefik.http.routers.blaze_dktk.middlewares=dktk_b_strip,test-auth"
|
||||
- "traefik.http.routers.blaze_dktk.tls=true"
|
||||
|
||||
|
||||
# dktk-fed-search-share:
|
||||
# image: "ghcr.io/samply/dktk-fed-search-share:pr-1"
|
||||
# container_name: bridgehead_dktk_share
|
||||
|
|
|
@ -9,10 +9,7 @@ echo
|
|||
bc=$(docker run --rm -ti xmartlabs/htpasswd $bc_user $bc_password)
|
||||
|
||||
if [ -z $bc_auth_users ]; then
|
||||
export bc_auth_users=$bc
|
||||
echo $bc_auth_users
|
||||
printf "Please run: export bc_auth_users=\"%q\"" $bc
|
||||
else
|
||||
export bc_auth_users="$bc_auth_users,$bc"
|
||||
echo $bc_auth_users
|
||||
echo "Please run: export bc_auth_users=\"${bc},$bc_auth_users\""
|
||||
fi
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
## Check if user is a su
|
||||
echo "Welcome to the starting a bridgehead. We will get your instance up and running in no time"
|
||||
echo "First we will check if all prerequisites are met ..."
|
||||
prerequisites="git docker docker-compose cat"
|
||||
prerequisites="git docker docker-compose"
|
||||
for prerequisite in $prerequisites; do
|
||||
$prerequisite --version 2>&1
|
||||
is_available=$?
|
||||
|
|
Loading…
Reference in New Issue