Skip to content

Commit 7e55310

Browse files
committed
rename tappd to dstack-guest-agent
1 parent 82ab801 commit 7e55310

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+269
-480
lines changed

Cargo.lock

Lines changed: 58 additions & 58 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ members = [
1414
"tdx-attest",
1515
"tdxctl",
1616
"iohash",
17-
"tappd",
18-
"tappd/rpc",
17+
"guest-agent",
18+
"guest-agent/rpc",
1919
"teepod",
2020
"teepod/rpc",
2121
"tproxy",
@@ -45,7 +45,7 @@ ra-rpc = { path = "ra-rpc", default-features = false }
4545
ra-tls = { path = "ra-tls" }
4646
tproxy-rpc = { path = "tproxy/rpc" }
4747
kms-rpc = { path = "kms/rpc" }
48-
tappd-rpc = { path = "tappd/rpc" }
48+
dstack-guest-agent-rpc = { path = "guest-agent/rpc" }
4949
teepod-rpc = { path = "teepod/rpc" }
5050
cc-eventlog = { path = "cc-eventlog" }
5151
supervisor = { path = "supervisor" }

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ Components in Dstack:
2626
- `teepod`: A service running in bare TDX host to manage CVMs
2727
- `tproxy`: A reverse proxy to forward TLS connections to CVMs
2828
- `kms`: A KMS server to generate keys for CVMs
29-
- `tappd`: A service running in CVM to serve containers' key derivation and attestation requests
29+
- `dstack-guest-agent`: A service running in CVM to serve containers' key derivation and attestation requests
3030
- `meta-dstack`: A Yocto meta layer to build CVM guest images
3131

3232
The overall architecture is shown below:
@@ -37,7 +37,7 @@ The overall architecture is shown below:
3737
```text
3838
dstack/
3939
kms/ A prototype KMS server
40-
tappd/ A service running in CVM to serve containers' key derivation and attestation requests.
40+
guest-agent/ A service running in CVM to serve containers' key derivation and attestation requests.
4141
tdxctl/ A CLI tool getting TDX quote, extending RTMR, generating cert for RA-TLS, etc.
4242
teepod/ A service running in bare TDX host to manage CVMs
4343
tproxy/ A reverse proxy to forward TLS connections to CVMs
@@ -151,7 +151,7 @@ After the container deployed, it should need some time to start the CVM and the
151151

152152
- Once the container is running, you can click the [Dashboard] button to see some information of the container. And the logs of the containers can be seen in the [Dashboard] page.
153153

154-
![tappd](./docs/assets/tappd.png)
154+
![dstack-guest-agent](./docs/assets/guest-agent.png)
155155

156156
- You can open tproxy's dashboard at [https://localhost:9070](https://localhost:9070) to see the CVM's wireguard ip address, as shown below:
157157

@@ -187,15 +187,15 @@ ssh [email protected]
187187

188188
To get a TDX quote within app containers:
189189

190-
1. Mount `/var/run/tappd.sock` to the target container in `docker-compose.yaml`
190+
1. Mount `/var/run/dstack.sock` to the target container in `docker-compose.yaml`
191191

192192
```yaml
193193
version: '3'
194194
services:
195195
nginx:
196196
image: nginx:latest
197197
volumes:
198-
- /var/run/tappd.sock:/var/run/tappd.sock
198+
- /var/run/dstack.sock:/var/run/dstack.sock
199199
ports:
200200
- "8080:80"
201201
restart: always
@@ -206,7 +206,7 @@ To get a TDX quote within app containers:
206206
```bash
207207
# The argument report_data accepts binary data encoding in hex string.
208208
# The actual report_data passing the to the underlying TDX driver is sha2_256(report_data).
209-
curl -X POST --unix-socket /var/run/tappd.sock -d '{"report_data": "0x1234deadbeef"}' http://localhost/prpc/Tappd.TdxQuote?json | jq .
209+
curl --unix-socket /var/run/dstack.sock http://localhost/GetQuote?report_data=0x1234deadbeef | jq .
210210
```
211211

212212
## Container logs

basefiles/app-compose.service

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[Unit]
22
Description=App Compose Service
33
Wants=docker.service
4-
After=docker.service tboot.service tappd.service
4+
After=docker.service tboot.service dstack-guest-agent.service
55

66
[Service]
77
Type=oneshot

basefiles/tappd.service renamed to basefiles/dstack-guest-agent.service

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
[Unit]
2-
Description=Tappd Service
2+
Description=Dstack Guest Agent Service
33
After=network.target tboot.service
44

55
[Service]
66
OOMScoreAdjust=-1000
7-
ExecStartPre=-/bin/rm -rf /var/run/tappd.sock
8-
ExecStart=/bin/tappd --watchdog -c /tapp/tappd.json
7+
ExecStart=/bin/dstack-guest-agent --watchdog -c /tapp/agent.json
98
Restart=always
109
User=root
1110
Group=root

basefiles/tappd.init

Lines changed: 0 additions & 87 deletions
This file was deleted.

basefiles/tboot.service

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[Unit]
22
Description=Guest Boot Service
33
After=network.target
4-
Before=app-compose.service tappd.service
4+
Before=app-compose.service dstack-guest-agent.service
55

66
[Service]
77
Type=oneshot
File renamed without changes.

docs/deployment.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ Especially the `KMS_CONTRACT_ADDR` variable set to the address of the KmsAuth Pr
9191
TEEPOD_RPC=unix:../../teepod-data/teepod.sock
9292
KMS_CONTRACT_ADDR=0xFE6C45aE66344CAEF5E5D7e2cbD476286D651875
9393
KMS_RPC_ADDR=0.0.0.0:9201
94-
TAPPD_ADDR=127.0.0.1:9205
94+
GUEST_AGENT_ADDR=127.0.0.1:9205
9595
ETH_RPC_URL=https://rpc.phala.network
9696
GIT_REV=HEAD
9797
OS_IMAGE=dstack-0.4.0
@@ -229,7 +229,7 @@ GIT_REV=HEAD
229229
TPROXY_RPC_ADDR=0.0.0.0:9202
230230
TPROXY_ADMIN_RPC_ADDR=127.0.0.1:9203
231231
TPROXY_SERVING_ADDR=0.0.0.0:9204
232-
TAPPD_ADDR=127.0.0.1:9206
232+
GUEST_AGENT_ADDR=127.0.0.1:9206
233233
WG_ADDR=0.0.0.0:9202
234234
```
235235

@@ -250,7 +250,7 @@ WG_ADDR: 0.0.0.0:9202
250250
TPROXY_RPC_ADDR: 0.0.0.0:9202
251251
TPROXY_ADMIN_RPC_ADDR: 127.0.0.1:9203
252252
TPROXY_SERVING_ADDR: 0.0.0.0:9204
253-
TAPPD_ADDR: 127.0.0.1:9206
253+
GUEST_AGENT_ADDR: 127.0.0.1:9206
254254
Continue? [y/N]
255255
```
256256

tappd/Cargo.toml renamed to guest-agent/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[package]
2-
name = "tappd"
2+
name = "dstack-guest-agent"
33
version.workspace = true
44
authors.workspace = true
55
edition.workspace = true
@@ -24,7 +24,7 @@ base64.workspace = true
2424
rinja.workspace = true
2525
git-version.workspace = true
2626
ra-rpc = { workspace = true, features = ["client", "rocket"] }
27-
tappd-rpc.workspace = true
27+
dstack-guest-agent-rpc.workspace = true
2828
ra-tls.workspace = true
2929
tdx-attest.workspace = true
3030
guest-api = { workspace = true, features = ["client"] }

0 commit comments

Comments
 (0)