Merge pull request #8 from nextcloud/fix-urls

Fix URLs
This commit is contained in:
Lukas Reschke
2021-11-30 14:26:49 +01:00
committed by GitHub

View File

@@ -374,7 +374,7 @@ class DockerActionManager
$containerName = $container->GetIdentifier();
// schedule the exec
$url = $this->BuildApiUrl(sprintf('/containers/%s/exec', urlencode($containerName)));
$url = $this->BuildApiUrl(sprintf('containers/%s/exec', urlencode($containerName)));
$response = json_decode(
$this->guzzleClient->request(
'POST',
@@ -391,14 +391,15 @@ class DockerActionManager
],
],
]
)->getBody()->getContents()
)->getBody()->getContents(),
true
);
// get the id from the response
$id = $response['Id'];
// start the exec
$url = $this->BuildApiUrl(sprintf('/exec/%s/start', $id));
$url = $this->BuildApiUrl(sprintf('exec/%s/start', $id));
$this->guzzleClient->request(
'POST',
$url,