]> _ Git - fluidbook-toolbox.git/commitdiff
wip #6549 @2
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Fri, 15 Dec 2023 16:51:07 +0000 (17:51 +0100)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Fri, 15 Dec 2023 16:51:07 +0000 (17:51 +0100)
app/Jobs/HostingUpdate.php
app/Models/FluidbookExternalInstallServer.php
bin/startup.sh

index 3078d0f7a5358ee54b73b0a63826a01639ad1e3a..a1c7f349849870d79b3f5330b697bd9d52542807 100644 (file)
@@ -12,8 +12,8 @@ use Cubist\Util\Text;
 class HostingUpdate extends Base
 {
     protected static $_data = [
-        'hosting' => ['host' => 'clockwork.cubedesigners.com', 'basepath' => '/data/fluidbook/hosting'],
-        'hosting2' => ['host' => 'clockwork.cubedesigners.com', 'basepath' => '/data/fluidbook/hosting2'],
+        'hosting' => ['host' => 'godzilla.cubedesigners.com', 'basepath' => '/data/fluidbook/hosting'],
+        'hosting2' => ['host' => 'godzilla.cubedesigners.com', 'basepath' => '/data/fluidbook/hosting2'],
         'ushosting' => ['host' => 'kingkong.cubedesigners.com', 'basepath' => '/home/fluidbook/data/hosting'],
     ];
 
index 126cadef1f5afda0a50842eae339e3ccedc7b598..3b5da904fbd7ac32b090d2fc9df0827390d9ab92 100644 (file)
@@ -3,6 +3,7 @@
 namespace App\Models;
 
 use App\Http\Controllers\Admin\Operations\ServerOperation;
+use App\Jobs\HostingUpdate;
 use Cubist\Backpack\Magic\Fields\Checkbox;
 use Cubist\Backpack\Magic\Fields\Table;
 use Cubist\Backpack\Magic\Fields\Textarea;
@@ -46,7 +47,7 @@ class FluidbookExternalInstallServer extends ExternalServer
     public function setFields()
     {
         $hostingProtocols = static::getHostingProtocols();
-        $nothostingProtocols = array_diff(array_keys($this->getProtocols()),$hostingProtocols);
+        $nothostingProtocols = array_diff(array_keys($this->getProtocols()), $hostingProtocols);
 
         parent::setFields();
         $this->getField('base_url')->setAttribute('when', ['protocol' => $nothostingProtocols]);
@@ -85,6 +86,7 @@ class FluidbookExternalInstallServer extends ExternalServer
     public function onSaved(): bool
     {
         $this->updateHtaccess();
+        dispatch(new HostingUpdate());
         return parent::onSaved();
     }
 
index 68f9102150fcb84f10c5318135300d3f61eb84de..0c28109a93e7c1123a1b296ef267f0b5737034ff 100644 (file)
@@ -44,14 +44,14 @@ mkdir -p /mnt/hosting
 if mountpoint -q "/mnt/hosting"; then
     :
 else
-    sshfs -o reconnect,ServerAliveInterval=15,ServerAliveCountMax=3 -o uid=1002 -o gid=33 -o allow_other fluidbook@clockwork.cubedesigners.com:/data/fluidbook/hosting /mnt/hosting
+    sshfs -o reconnect,ServerAliveInterval=15,ServerAliveCountMax=3 -o uid=1002 -o gid=33 -o allow_other fluidbook@godzilla.cubedesigners.com:/data/fluidbook/hosting /mnt/hosting
 fi
 
 mkdir -p /mnt/hosting2
 if mountpoint -q "/mnt/hosting2"; then
     :
 else
-    sshfs -o reconnect,ServerAliveInterval=15,ServerAliveCountMax=3 -o uid=1002 -o gid=33 -o allow_other fluidbook@clockwork.cubedesigners.com:/data/fluidbook/hosting2 /mnt/hosting2
+    sshfs -o reconnect,ServerAliveInterval=15,ServerAliveCountMax=3 -o uid=1002 -o gid=33 -o allow_other fluidbook@godzilla.cubedesigners.com:/data/fluidbook/hosting2 /mnt/hosting2
 fi
 
 mkdir -p /application/usstorage