From 7c84faa7b5002aefe96a1fa981134a06226ae5d6 Mon Sep 17 00:00:00 2001 From: Andrew Gerrand Date: Wed, 10 Jul 2013 19:34:58 +1000 Subject: [PATCH] fix dev-cammount Change-Id: I22097d95ae12491336303ae9ce545c55cba1a6da --- dev-cammount | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/dev-cammount b/dev-cammount index b4bb23e8f..22f3a4a56 100755 --- a/dev-cammount +++ b/dev-cammount @@ -16,13 +16,23 @@ if (@ARGV) { } my $cammount = build_bin("./cmd/cammount"); +unless (-x $cammount) { die "Failed to find $cammount" } my $dir = "/tmp/cammount-dir"; mkdir $dir, 0700 unless -d $dir; try_unmount(); print "Mounting on $dir ...\n"; + +# Respected by camli/osutil: +$ENV{"CAMLI_CONFIG_DIR"} = "$Bin/config/dev-client-dir"; + +# Respected by env expansions in config/dev-client-dir/config +$ENV{"CAMLI_SECRET_RING"} = "$Bin/pkg/jsonsign/testdata/test-secring.gpg"; +$ENV{"CAMLI_KEYID"} = "26F5ABDA"; +$ENV{"CAMLI_DEV_KEYBLOBS"} = "$Bin/config/dev-client-dir/keyblobs"; $ENV{"CAMLI_AUTH"} = "userpass:camlistore:pass3179"; + system("$cammount", "--server=http://localhost:3179/bs", $dir, @blobref_arg) and warn "cammount failure: $!\n"; warn "Failed to unmount\n" unless try_unmount();