fix(service): ensure configuration changes are properly tracked and dispatched
This commit is contained in:
parent
b181e5bb33
commit
13a9816770
3 changed files with 3 additions and 1 deletions
|
|
@ -19,6 +19,7 @@ public function handle(Service $service, bool $pullLatestImages = false, bool $s
|
|||
StopService::run(service: $service, dockerCleanup: false);
|
||||
}
|
||||
$service->saveComposeConfigs();
|
||||
$service->isConfigurationChanged(save: true);
|
||||
$commands[] = 'cd '.$service->workdir();
|
||||
$commands[] = "echo 'Saved configuration files to {$service->workdir()}.'";
|
||||
if ($pullLatestImages) {
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ public function serviceChecked()
|
|||
$this->service->databases->each(function ($database) {
|
||||
$database->refresh();
|
||||
});
|
||||
if (is_null($this->service->config_hash) || $this->service->isConfigurationChanged()) {
|
||||
if (is_null($this->service->config_hash)) {
|
||||
$this->service->isConfigurationChanged(true);
|
||||
}
|
||||
$this->dispatch('configurationChanged');
|
||||
|
|
|
|||
|
|
@ -170,6 +170,7 @@ public function submit()
|
|||
$this->syncData(true);
|
||||
$this->dispatch('success', 'Environment variable updated.');
|
||||
$this->dispatch('envsUpdated');
|
||||
$this->dispatch('configurationChanged');
|
||||
} catch (\Exception $e) {
|
||||
return handleError($e);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue