-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Akihiko Odaki <[email protected]>
- Loading branch information
1 parent
ebe550e
commit 78712a8
Showing
1 changed file
with
5 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
"-device tpm-tis,tpmdev=tpm0" | ||
], | ||
"define_variables": { | ||
"@tpm_pid@": "@workspace@/swtpm_@run_id@_@[email protected]", | ||
"@tpm_state_dir@": "@workspace@/swtpm_state_@run_id@_@client_id@", | ||
"@tpm_socket@": "/tmp/swtpm_@run_id@_@client_id@_sock" | ||
}, | ||
|
@@ -15,6 +16,9 @@ | |
], | ||
"pre_start_commands": [ | ||
"rm -f @tpm_socket@", | ||
"swtpm socket --daemon --tpm2 --tpmstate dir=@tpm_state_dir@ --ctrl type=unixio,path=@tpm_socket@ --log file=@tpm_state_dir@/swtpm.log,level=20" | ||
"swtpm socket --daemon --pid file=@tpm_pid@ --tpm2 --tpmstate dir=@tpm_state_dir@ --ctrl type=unixio,path=@tpm_socket@ --log file=@tpm_state_dir@/swtpm.log,level=20" | ||
], | ||
"post_stop_commands": [ | ||
"kill $(cat @tpm_pid@) || true" | ||
] | ||
} |