summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMagnus Ahltorp <map@kth.se>2014-09-28 02:01:15 +0200
committerMagnus Ahltorp <map@kth.se>2014-09-28 02:01:15 +0200
commitc915ef319d63f73231202443419dcad3aa32b5f4 (patch)
tree75a8a36a711bb805b549e05fbe78f1ae184eb8b9
parenteca189ce80ec353035902dc0c361c748e042371a (diff)
Use raw file storage
-rw-r--r--Makefile3
-rw-r--r--catlfish.config8
-rw-r--r--src/catlfish.erl2
3 files changed, 10 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 5a13905..df00505 100644
--- a/Makefile
+++ b/Makefile
@@ -7,9 +7,10 @@ release:
mkdir rel
./makerelease.erl
(cd rel; \
- ln -s ../../plop/Mnesia.nonode@nohost .; \
ln -s ../../plop/test .)
cp httpd_props.conf rel
cp catlfish.config rel
mkdir rel/catlfish
+ mkdir rel/db
+ printf "0" > rel/db/treesize
cp -r webroot rel/catlfish
diff --git a/catlfish.config b/catlfish.config
index cda8789..9b80c6e 100644
--- a/catlfish.config
+++ b/catlfish.config
@@ -9,4 +9,10 @@
{error_logger_mf_maxfiles, 10}]},
{inets,
[{services,
- [{httpd, [{proplist_file, "httpd_props.conf"}]}]}]}].
+ [{httpd, [{proplist_file, "httpd_props.conf"}]}]}]},
+ {plop,
+ [{entry_root_path, "db/certentries/"},
+ {index_path, "db/index"},
+ {entryhash_root_path, "db/entryhash/"},
+ {treesize_path, "db/treesize"},
+ {indexforhash_root_path, "db/certindex/"}]}].
diff --git a/src/catlfish.erl b/src/catlfish.erl
index bd3c106..d105591 100644
--- a/src/catlfish.erl
+++ b/src/catlfish.erl
@@ -146,7 +146,7 @@ unpack_entry(Entry) ->
x_entries([]) ->
[];
x_entries([H|T]) ->
- [_Index, _Hash, Entry] = H,
+ {_Index, _Hash, Entry} = H,
{Timestamp, LeafCertVector, CertChainVector} = unpack_entry(Entry),
MTL = build_mtl(Timestamp, LeafCertVector),
[{[{leaf_input, base64:encode(MTL)}, {extra_data, base64:encode(CertChainVector)}]} |