-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Drupal, Grav, Nextcloud and Python as installable/creatable Apps
- Loading branch information
Showing
4 changed files
with
142 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import { ExecRenderBaseCommand } from "../../../rendering/react/ExecRenderBaseCommand.js"; | ||
import React from "react"; | ||
import { | ||
AppInstallationResult, | ||
AppInstaller, | ||
} from "../../../lib/app/Installer.js"; | ||
|
||
export const staticInstaller = new AppInstaller( | ||
"be57d166-dae9-4480-bae2-da3f3c6f0a2e", | ||
"custom python site", | ||
["document-root", "site-title", "wait"] as const, | ||
); | ||
|
||
export default class InstallNode extends ExecRenderBaseCommand< | ||
typeof InstallNode, | ||
AppInstallationResult | ||
> { | ||
static description = staticInstaller.description; | ||
static flags = staticInstaller.flags; | ||
|
||
protected async exec(): Promise<{ appInstallationId: string }> { | ||
return staticInstaller.exec( | ||
this.apiClient, | ||
this.args, | ||
this.flags, | ||
this.config, | ||
); | ||
} | ||
|
||
protected render(result: AppInstallationResult): React.ReactNode { | ||
return staticInstaller.render(result, this.flags); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import { ExecRenderBaseCommand } from "../../../rendering/react/ExecRenderBaseCommand.js"; | ||
import React from "react"; | ||
import { | ||
AppInstallationResult, | ||
AppInstaller, | ||
} from "../../../lib/app/Installer.js"; | ||
|
||
const installer = new AppInstaller( | ||
"3d8a261a-3d6f-4e09-b68c-bfe90aece514", | ||
"Drupal", | ||
[ | ||
"version", | ||
"host", | ||
"admin-user", | ||
"admin-email", | ||
"admin-pass", | ||
"site-title", | ||
"wait", | ||
] as const, | ||
); | ||
|
||
export default class InstallShopware6 extends ExecRenderBaseCommand< | ||
typeof InstallShopware6, | ||
AppInstallationResult | ||
> { | ||
static description = installer.description; | ||
static flags = installer.flags; | ||
|
||
protected async exec(): Promise<{ appInstallationId: string }> { | ||
return installer.exec(this.apiClient, this.args, this.flags, this.config); | ||
} | ||
|
||
protected render(result: AppInstallationResult): React.ReactNode { | ||
return installer.render(result, this.flags); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import { ExecRenderBaseCommand } from "../../../rendering/react/ExecRenderBaseCommand.js"; | ||
import React from "react"; | ||
import { | ||
AppInstallationResult, | ||
AppInstaller, | ||
} from "../../../lib/app/Installer.js"; | ||
|
||
const installer = new AppInstaller( | ||
"d3a465da-75a2-44ab-8e81-6960055f6255", | ||
"Grav", | ||
[ | ||
"version", | ||
"admin-user", | ||
"admin-email", | ||
"admin-pass", | ||
"admin-firstname", | ||
"admin-lastname", | ||
"site-title", | ||
"wait", | ||
] as const, | ||
); | ||
|
||
export default class InstallGrav extends ExecRenderBaseCommand< | ||
typeof InstallGrav, | ||
AppInstallationResult | ||
> { | ||
static description = installer.description; | ||
static flags = installer.flags; | ||
|
||
protected async exec(): Promise<{ appInstallationId: string }> { | ||
return installer.exec(this.apiClient, this.args, this.flags, this.config); | ||
} | ||
|
||
protected render(result: AppInstallationResult): React.ReactNode { | ||
return installer.render(result, this.flags); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import { ExecRenderBaseCommand } from "../../../rendering/react/ExecRenderBaseCommand.js"; | ||
import React from "react"; | ||
import { | ||
AppInstallationResult, | ||
AppInstaller, | ||
} from "../../../lib/app/Installer.js"; | ||
|
||
const installer = new AppInstaller( | ||
"0b97d59f-ee13-4f18-a1f6-53e1beaf2e70", | ||
"Shopware 6", | ||
[ | ||
"version", | ||
"host", | ||
"admin-user", | ||
"admin-email", | ||
"admin-pass", | ||
"site-title", | ||
"wait", | ||
] as const, | ||
); | ||
|
||
export default class InstallShopware6 extends ExecRenderBaseCommand< | ||
typeof InstallShopware6, | ||
AppInstallationResult | ||
> { | ||
static description = installer.description; | ||
static flags = installer.flags; | ||
|
||
protected async exec(): Promise<{ appInstallationId: string }> { | ||
return installer.exec(this.apiClient, this.args, this.flags, this.config); | ||
} | ||
|
||
protected render(result: AppInstallationResult): React.ReactNode { | ||
return installer.render(result, this.flags); | ||
} | ||
} |