mirror of
https://github.com/appwrite/appwrite
synced 2026-05-23 00:49:02 +00:00
Fix response model missing fallbackFile
This commit is contained in:
parent
f6122157c7
commit
40e343d17d
7 changed files with 36 additions and 6 deletions
|
|
@ -37506,6 +37506,11 @@
|
|||
"type": "string",
|
||||
"description": "Site serve runtime.",
|
||||
"x-example": "static-1"
|
||||
},
|
||||
"fallbackFile": {
|
||||
"type": "string",
|
||||
"description": "Name of fallback file to use instead of 404 page. If null, Appwrite 404 page will be displayed.",
|
||||
"x-example": "index.html"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
|
|
@ -37529,7 +37534,8 @@
|
|||
"providerSilentMode",
|
||||
"specification",
|
||||
"buildRuntime",
|
||||
"serveRuntime"
|
||||
"serveRuntime",
|
||||
"fallbackFile"
|
||||
]
|
||||
},
|
||||
"templateSite": {
|
||||
|
|
|
|||
|
|
@ -27740,6 +27740,11 @@
|
|||
"type": "string",
|
||||
"description": "Site serve runtime.",
|
||||
"x-example": "static-1"
|
||||
},
|
||||
"fallbackFile": {
|
||||
"type": "string",
|
||||
"description": "Name of fallback file to use instead of 404 page. If null, Appwrite 404 page will be displayed.",
|
||||
"x-example": "index.html"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
|
|
@ -27763,7 +27768,8 @@
|
|||
"providerSilentMode",
|
||||
"specification",
|
||||
"buildRuntime",
|
||||
"serveRuntime"
|
||||
"serveRuntime",
|
||||
"fallbackFile"
|
||||
]
|
||||
},
|
||||
"function": {
|
||||
|
|
|
|||
|
|
@ -38060,6 +38060,11 @@
|
|||
"type": "string",
|
||||
"description": "Site serve runtime.",
|
||||
"x-example": "static-1"
|
||||
},
|
||||
"fallbackFile": {
|
||||
"type": "string",
|
||||
"description": "Name of fallback file to use instead of 404 page. If null, Appwrite 404 page will be displayed.",
|
||||
"x-example": "index.html"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
|
|
@ -38083,7 +38088,8 @@
|
|||
"providerSilentMode",
|
||||
"specification",
|
||||
"buildRuntime",
|
||||
"serveRuntime"
|
||||
"serveRuntime",
|
||||
"fallbackFile"
|
||||
]
|
||||
},
|
||||
"templateSite": {
|
||||
|
|
|
|||
|
|
@ -28271,6 +28271,11 @@
|
|||
"type": "string",
|
||||
"description": "Site serve runtime.",
|
||||
"x-example": "static-1"
|
||||
},
|
||||
"fallbackFile": {
|
||||
"type": "string",
|
||||
"description": "Name of fallback file to use instead of 404 page. If null, Appwrite 404 page will be displayed.",
|
||||
"x-example": "index.html"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
|
|
@ -28294,7 +28299,8 @@
|
|||
"providerSilentMode",
|
||||
"specification",
|
||||
"buildRuntime",
|
||||
"serveRuntime"
|
||||
"serveRuntime",
|
||||
"fallbackFile"
|
||||
]
|
||||
},
|
||||
"function": {
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ class CreateSite extends Base
|
|||
->callback([$this, 'action']);
|
||||
}
|
||||
|
||||
public function action(string $siteId, string $name, string $framework, bool $enabled, int $timeout, string $installCommand, string $buildCommand, string $outputDirectory, string $subdomain, string $buildRuntime, string $serveRuntime, string $installationId, string $fallbackFile, string $providerRepositoryId, string $providerBranch, bool $providerSilentMode, string $providerRootDirectory, string $templateRepository, string $templateOwner, string $templateRootDirectory, string $templateVersion, string $specification, Request $request, Response $response, Database $dbForProject, Document $project, Document $user, Event $queueForEvents, Build $queueForBuilds, Database $dbForConsole, GitHub $github)
|
||||
public function action(string $siteId, string $name, string $framework, bool $enabled, int $timeout, string $installCommand, string $buildCommand, string $outputDirectory, string $subdomain, string $buildRuntime, string $serveRuntime, string $installationId, ?string $fallbackFile, string $providerRepositoryId, string $providerBranch, bool $providerSilentMode, string $providerRootDirectory, string $templateRepository, string $templateOwner, string $templateRootDirectory, string $templateVersion, string $specification, Request $request, Response $response, Database $dbForProject, Document $project, Document $user, Event $queueForEvents, Build $queueForBuilds, Database $dbForConsole, GitHub $github)
|
||||
{
|
||||
$sitesDomain = System::getEnv('_APP_DOMAIN_SITES', '');
|
||||
$routeSubdomain = '';
|
||||
|
|
|
|||
|
|
@ -87,7 +87,7 @@ class UpdateSite extends Base
|
|||
->callback([$this, 'action']);
|
||||
}
|
||||
|
||||
public function action(string $siteId, string $name, string $framework, bool $enabled, int $timeout, string $installCommand, string $buildCommand, string $outputDirectory, string $buildRuntime, string $serveRuntime, string $fallbackFile, string $installationId, ?string $providerRepositoryId, string $providerBranch, bool $providerSilentMode, string $providerRootDirectory, string $specification, Request $request, Response $response, Database $dbForProject, Document $project, Event $queueForEvents, Build $queueForBuilds, Database $dbForConsole, GitHub $github)
|
||||
public function action(string $siteId, string $name, string $framework, bool $enabled, int $timeout, string $installCommand, string $buildCommand, string $outputDirectory, string $buildRuntime, string $serveRuntime, ?string $fallbackFile, string $installationId, ?string $providerRepositoryId, string $providerBranch, bool $providerSilentMode, string $providerRootDirectory, string $specification, Request $request, Response $response, Database $dbForProject, Document $project, Event $queueForEvents, Build $queueForBuilds, Database $dbForConsole, GitHub $github)
|
||||
{
|
||||
// TODO: If only branch changes, re-deploy
|
||||
$site = $dbForProject->getDocument('sites', $siteId);
|
||||
|
|
|
|||
|
|
@ -137,6 +137,12 @@ class Site extends Model
|
|||
'default' => '',
|
||||
'example' => 'static-1',
|
||||
])
|
||||
->addRule('fallbackFile', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Name of fallback file to use instead of 404 page. If null, Appwrite 404 page will be displayed.',
|
||||
'default' => null,
|
||||
'example' => 'index.html',
|
||||
])
|
||||
;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue