Skip to content

Commit

Permalink
Merge pull request #8 from nextcloud/fix-urls
Browse files Browse the repository at this point in the history
Fix URLs
  • Loading branch information
LukasReschke authored Nov 30, 2021
2 parents 878baf4 + 7962ec5 commit 3f67259
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions php/src/Docker/DockerActionManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ public function sendNotification(Container $container, string $subject, string $
$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',
Expand All @@ -391,14 +391,15 @@ public function sendNotification(Container $container, string $subject, string $
],
],
]
)->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,
Expand Down

0 comments on commit 3f67259

Please sign in to comment.