-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplification : avoid using a docker host in a container
- Loading branch information
Thierry RAMORASOAVINA
committed
Aug 14, 2024
1 parent
9fc5b7f
commit 6593606
Showing
4 changed files
with
104 additions
and
127 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 16 additions & 18 deletions
34
packaging/docker/khiopspydev/run_fake_remote_file_servers.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,25 @@ | ||
#!/bin/bash | ||
# first start the docker daemon | ||
service docker start | ||
|
||
# File server for GCS | ||
# We cannot start the fake remote files servers until the source code is fetched | ||
# because we expose pre-provisioned files to be read | ||
|
||
ROOT_FOLDER=${1:-.} # defaults to current folder | ||
|
||
# File server for GCS (runs in background) | ||
# WARNING : there are 3 major features actived by the options ... | ||
# -v : the volume mounted exposes pre-provisioned files to be read remotely : the direct child folders will be the bucket names | ||
# -data : exposes pre-provisioned files to be read remotely : the direct child folders will be the bucket names | ||
# -filesystem-root : let upload and read new files remotely at the same location as the source | ||
# -public-host : must expose localhost (https://github.com/fsouza/fake-gcs-server/issues/201) | ||
docker run --rm \ | ||
-d \ | ||
-p 4443:4443 \ | ||
--name fake-gcs-server \ | ||
-v ./tests/resources/remote-access:/data fsouza/fake-gcs-server \ | ||
nohup /bin/fake-gcs-server \ | ||
-data "${ROOT_FOLDER}"/tests/resources/remote-access \ | ||
-filesystem-root "${ROOT_FOLDER}"/tests/resources/remote-access \ | ||
-scheme http \ | ||
-filesystem-root /data \ | ||
-public-host localhost | ||
-public-host localhost & | ||
|
||
# File server for S3 | ||
# File server for S3 (runs in background) | ||
# WARNING : | ||
# -v : the volume mounted exposes pre-provisioned files : the direct child folders will be the bucket names | ||
# -r : exposes pre-provisioned files : the direct child folders will be the bucket names | ||
# these files were uploaded once because fake-s3 creates metadata | ||
docker run --rm \ | ||
-d \ | ||
-p 4569:4569 \ | ||
--name my_s3 \ | ||
-v ./tests/resources/remote-access:/fakes3_root lphoward/fake-s3 | ||
nohup /usr/local/bin/fakes3 \ | ||
-r "${ROOT_FOLDER}"/tests/resources/remote-access \ | ||
-p 4569 & |