Error message:
+ ./substratee-worker signing-key
+ tee worker1_signing-key.log
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: SGX_ERROR_UNEXPECTED', src/lib.rs:115:18
note: Call backtrace::enable_backtrace with 'PrintFormat::Short/Full' for a backtrace.
fatal runtime error: failed to initiate panic, error 5
Illegal instruction (core dumped)
This is caused by the missing shards directory. If you create - before performing any actions - the directory, everything is fine.
Caused by the line
let shards = state::list_shards().unwrap();
which calls
let files = fs::read_dir(SHARDS_PATH).sgx_error()?;