Skip to content

Commit

Permalink
fix(robot): remove rootfs from device endpoint
Browse files Browse the repository at this point in the history
longhorn/longhorn-9422

Signed-off-by: Chin-Ya Huang <[email protected]>
  • Loading branch information
c3y1huang authored and yangchiu committed Sep 16, 2024
1 parent c084457 commit 2e4b3b9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions e2e/libs/volume/crd.py
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,7 @@ def get_endpoint(self, volume_name):

def write_random_data(self, volume_name, size, data_id):
node_name = self.get(volume_name)["spec"]["nodeID"]
endpoint = f"{HOST_ROOTFS}{self.get_endpoint(volume_name)}"
endpoint = self.get_endpoint(volume_name)

cmd = [
"sh", "-c",
Expand All @@ -383,7 +383,7 @@ def write_random_data(self, volume_name, size, data_id):

def keep_writing_data(self, volume_name, size):
node_name = self.get(volume_name)["spec"]["nodeID"]
endpoint = f"{HOST_ROOTFS}{self.get_endpoint(volume_name)}"
endpoint = self.get_endpoint(volume_name)
logging(f"Keeping writing data to volume {volume_name}")
res = self.node_exec.issue_cmd(
node_name,
Expand Down Expand Up @@ -435,7 +435,7 @@ def check_data_checksum(self, volume_name, data_id):

def get_checksum(self, volume_name):
node_name = self.get(volume_name)["spec"]["nodeID"]
endpoint = f"{HOST_ROOTFS}{self.get_endpoint(volume_name)}"
endpoint = self.get_endpoint(volume_name)
checksum = self.node_exec.issue_cmd(
node_name,
["sh", "-c", f"md5sum {endpoint} | awk \'{{print $1}}\'"])
Expand Down
2 changes: 1 addition & 1 deletion e2e/libs/volume/rest.py
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ def check_data_checksum(self, volume_name, data_id):

def get_checksum(self, volume_name):
node_name = self.get(volume_name).controllers[0].hostId
endpoint = f"{HOST_ROOTFS}{self.get_endpoint(volume_name)}"
endpoint = self.get_endpoint(volume_name)
checksum = self.node_exec.issue_cmd(
node_name,
["sh", "-c", f"md5sum {endpoint} | awk \'{{print $1}}\'"])
Expand Down

0 comments on commit 2e4b3b9

Please sign in to comment.