(a) paf 0.1.0 is released now, which works fine (no pins needed)
(b) use 16 as program_block_size, not 512 - this results in a working unikernel (c) report data pushed into the map
This commit is contained in:
parent
c3d66b96b1
commit
5d86452f5f
3 changed files with 4 additions and 7 deletions
|
@ -1,4 +0,0 @@
|
|||
Please note that the following pins are needed for getting this to work:
|
||||
- paf.0.0.9 git+https://github.com/hannesm/paf-le-chien.git#h2-0.9.0
|
||||
- paf-cohttp.0.0.9 git+https://github.com/hannesm/paf-le-chien.git#h2-0.9.0
|
||||
- paf-le.0.0.9 git+https://github.com/hannesm/paf-le-chien.git#h2-0.9.0
|
|
@ -49,7 +49,7 @@ let git_client =
|
|||
|
||||
let program_block_size =
|
||||
let doc = Key.Arg.info [ "program-block-size" ] in
|
||||
Key.(create "program_block_size" Arg.(opt int 512 doc))
|
||||
Key.(create "program_block_size" Arg.(opt int 16 doc))
|
||||
|
||||
let kv_rw =
|
||||
let block = block_of_file "db" in
|
||||
|
|
|
@ -299,7 +299,7 @@ module Make
|
|||
| Ok data ->
|
||||
let cs = Cstruct.of_string data in
|
||||
let digest = Mirage_crypto.Hash.digest `SHA256 cs in
|
||||
if Cstruct.equal digest (Cstruct.of_string name) then
|
||||
if Cstruct.equal digest (Cstruct.of_string name) then begin
|
||||
let md5 = Mirage_crypto.Hash.digest `MD5 cs
|
||||
and sha512 = Mirage_crypto.Hash.digest `SHA512 cs
|
||||
in
|
||||
|
@ -307,8 +307,9 @@ module Make
|
|||
and sha512s = SM.add (Cstruct.to_string sha512) name t.sha512s
|
||||
in
|
||||
t.md5s <- md5s ; t.sha512s <- sha512s;
|
||||
Logs.info (fun m -> m "added %s" (hex_to_string name));
|
||||
Lwt.return_unit
|
||||
else begin
|
||||
end else begin
|
||||
Logs.err (fun m -> m "corrupt data, expected %s, read %s"
|
||||
(hex_to_string name)
|
||||
(hex_to_string (Cstruct.to_string digest)));
|
||||
|
|
Loading…
Reference in a new issue