fix(CheckProxy, Status): prevent proxy checks when force_stop is active; remove debug statement in General
This commit is contained in:
@@ -27,7 +27,7 @@ class CheckProxy
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
$proxyType = $server->proxyType();
|
$proxyType = $server->proxyType();
|
||||||
if (is_null($proxyType) || $proxyType === 'NONE' || $server->proxy->force_stop) {
|
if ((is_null($proxyType) || $proxyType === 'NONE' || $server->proxy->force_stop) && ! $fromUI) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (! $server->isProxyShouldRun()) {
|
if (! $server->isProxyShouldRun()) {
|
||||||
@@ -65,7 +65,6 @@ class CheckProxy
|
|||||||
if ($server->id === 0) {
|
if ($server->id === 0) {
|
||||||
$ip = 'host.docker.internal';
|
$ip = 'host.docker.internal';
|
||||||
}
|
}
|
||||||
|
|
||||||
$portsToCheck = ['80', '443'];
|
$portsToCheck = ['80', '443'];
|
||||||
|
|
||||||
foreach ($portsToCheck as $port) {
|
foreach ($portsToCheck as $port) {
|
||||||
|
|||||||
@@ -455,7 +455,6 @@ class General extends Component
|
|||||||
{
|
{
|
||||||
$config = GenerateConfig::run($this->application, true);
|
$config = GenerateConfig::run($this->application, true);
|
||||||
$fileName = str($this->application->name)->slug()->append('_config.json');
|
$fileName = str($this->application->name)->slug()->append('_config.json');
|
||||||
dd($config);
|
|
||||||
|
|
||||||
return response()->streamDownload(function () use ($config) {
|
return response()->streamDownload(function () use ($config) {
|
||||||
echo $config;
|
echo $config;
|
||||||
|
|||||||
@@ -34,6 +34,9 @@ class Status extends Component
|
|||||||
public function checkProxy(bool $notification = false)
|
public function checkProxy(bool $notification = false)
|
||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
|
if ($this->server->proxy->force_stop) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
if ($this->polling) {
|
if ($this->polling) {
|
||||||
if ($this->numberOfPolls >= 10) {
|
if ($this->numberOfPolls >= 10) {
|
||||||
$this->polling = false;
|
$this->polling = false;
|
||||||
|
|||||||
Reference in New Issue
Block a user