diff --git a/website/blobserver-example/root/GENERATION.dat b/website/blobserver-example/root/GENERATION.dat new file mode 100644 index 000000000..24ccf5da7 --- /dev/null +++ b/website/blobserver-example/root/GENERATION.dat @@ -0,0 +1,16 @@ +5f053cc6143f2624ade4ff193b2ae0dfa2fc8b68 + +This file's random string on the first line is an optimization and +paranoia facility for clients. + +If the client sees the same random string in multiple upload sessions, +it assumes that the blobserver still has all the same blobs, and also +it's the same server. This mechanism is not fundamental to +Camlistore's operation: the client could also check each blob before +uploading, or enumerate all blobs from the server too. This is purely +an optimization so clients can mix this value into their "is this file +uploaded?" local cache keys. + +If you deleted any blobs (or suspect any were corrupted), it's best to +delete this file so clients can safely re-upload them. + diff --git a/website/camweb.go b/website/camweb.go index f375032e2..c6680b91b 100644 --- a/website/camweb.go +++ b/website/camweb.go @@ -282,6 +282,8 @@ func runAsChild(res string) { log.Fatalf("Could not find %v in $PATH: %v", res, err) } cmd := exec.Command(cmdName) + cmd.Stderr = os.Stderr + cmd.Stdout = os.Stdout log.Printf("Running %v", res) if err := cmd.Start(); err != nil { log.Fatal("Program %v failed to start: %v", res, err) diff --git a/website/scripts/run-blobserver b/website/scripts/run-blobserver index c606cf1e9..7aa2c6853 100755 --- a/website/scripts/run-blobserver +++ b/website/scripts/run-blobserver @@ -1,16 +1,16 @@ #!/bin/sh set -e -Bin=$(dirname $( readlink -f $0)) +Bin=$(perl -MFindBin -e 'print $FindBin::Bin') export CAMLI_PASSWORD=`cat $HOME/.config/camlistore/camorg-blobserver.pass` -export CAMLI_ROOT=$Bin/../blobserver-example/root +export CAMLI_ROOT=$Bin/blobserver-example/root -cd $Bin/../.. +cd $Bin/.. go run make.go \ -embed_static=false \ -targets=camlistore.org/server/camlistored && \ ./bin/camlistored \ - -configfile=$Bin/../blobserver-example/example-blobserver-config.json \ + -configfile=$Bin/blobserver-example/example-blobserver-config.json \ -listen=:3179 "$@"