An open-source, self-hostable PaaS alternative to Vercel, Heroku & Netlify that lets you easily deploy static sites, databases, full-stack applications and 360+ one-click services on your own servers.
PHP coolifydatabasesdeploymentdockerdocker-composeinertiajslaravelmariadbmysqlnextjsnodejsphppostgresredisself-hostedself-hostingserverstatic-sitesveltesvelte5
refactor: Add authorization check in ExecuteContainerCommand mount method
Andras Bacsaid373815f989b
diff --git a/app/Livewire/Project/Shared/ExecuteContainerCommand.php b/app/Livewire/Project/Shared/ExecuteContainerCommand.phpindex 79f32ab8b0..d954436215 100644--- a/app/Livewire/Project/Shared/ExecuteContainerCommand.php+++ b/app/Livewire/Project/Shared/ExecuteContainerCommand.php@@ -33,6 +33,9 @@ class ExecuteContainerCommand extends Componentpublic function mount(){+ if (! auth()->user()->isAdmin()) {+ abort(403);+ }$this->parameters = get_route_parameters();$this->containers = collect();$this->servers = collect();@@ -130,7 +133,6 @@ class ExecuteContainerCommand extends Component{try {$container_name = data_get($this->container, 'container.Names');- ray($this->container);if (is_null($container_name)) {throw new \RuntimeException('Container not found.');}