Linting.
This commit is contained in:
parent
0f4dcbc3e2
commit
b6e5658f4e
|
@ -1,5 +1,4 @@
|
|||
<script>
|
||||
|
||||
import { Label, DropdownMenu } from "@budibase/bbui"
|
||||
import ThemeEditor from "./ThemeEditor.svelte"
|
||||
|
||||
|
|
|
@ -27,7 +27,6 @@
|
|||
}
|
||||
|
||||
function updateSelfHosting(event) {
|
||||
|
||||
if (hostingInfo.type === "cloud" && event.target.checked) {
|
||||
hostingInfo.hostingUrl = "localhost:10000"
|
||||
hostingInfo.useHttps = false
|
||||
|
@ -41,10 +40,7 @@
|
|||
})
|
||||
</script>
|
||||
|
||||
<ModalContent
|
||||
title="Builder settings"
|
||||
confirmText="Save"
|
||||
onConfirm={save}>
|
||||
<ModalContent title="Builder settings" confirmText="Save" onConfirm={save}>
|
||||
<h5>Theme</h5>
|
||||
<ThemeEditor />
|
||||
<h5>Hosting</h5>
|
||||
|
@ -52,7 +48,11 @@
|
|||
This section contains settings that relate to the deployment and hosting of
|
||||
apps made in this builder.
|
||||
</p>
|
||||
<Toggle thin text="Self hosted" on:change={updateSelfHosting} bind:checked={selfhosted} />
|
||||
<Toggle
|
||||
thin
|
||||
text="Self hosted"
|
||||
on:change={updateSelfHosting}
|
||||
bind:checked={selfhosted} />
|
||||
{#if selfhosted}
|
||||
<Input bind:value={hostingInfo.hostingUrl} label="Hosting URL" />
|
||||
<Input bind:value={hostingInfo.selfHostKey} label="Hosting Key" />
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
<script>
|
||||
import { writable } from "svelte/store"
|
||||
import { store, automationStore, backendUiStore, hostingStore } from "builderStore"
|
||||
import {
|
||||
store,
|
||||
automationStore,
|
||||
backendUiStore,
|
||||
hostingStore,
|
||||
} from "builderStore"
|
||||
import { string, object } from "yup"
|
||||
import api, { get } from "builderStore/api"
|
||||
import Form from "@svelteschool/svelte-forms"
|
||||
|
@ -12,7 +17,7 @@
|
|||
import { fade } from "svelte/transition"
|
||||
import { post } from "builderStore/api"
|
||||
import analytics from "analytics"
|
||||
import {onMount} from "svelte"
|
||||
import { onMount } from "svelte"
|
||||
|
||||
//Move this to context="module" once svelte-forms is updated so that it can bind to stores correctly
|
||||
const createAppStore = writable({ currentStep: 0, values: {} })
|
||||
|
|
|
@ -11,7 +11,7 @@ const PUBLIC_READ_POLICY = {
|
|||
{
|
||||
Effect: "Allow",
|
||||
Principal: {
|
||||
AWS: ["*"]
|
||||
AWS: ["*"],
|
||||
},
|
||||
Action: "s3:GetObject",
|
||||
Resource: [`arn:aws:s3:::${APP_BUCKET}/*`],
|
||||
|
@ -65,8 +65,7 @@ async function getMinioSession() {
|
|||
Bucket: APP_BUCKET,
|
||||
})
|
||||
.promise()
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
throw err
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,10 @@
|
|||
const env = require("../environment")
|
||||
|
||||
module.exports = async (ctx, next) => {
|
||||
if (!ctx.request.body.selfHostKey || env.SELF_HOST_KEY !== ctx.request.body.selfHostKey) {
|
||||
if (
|
||||
!ctx.request.body.selfHostKey ||
|
||||
env.SELF_HOST_KEY !== ctx.request.body.selfHostKey
|
||||
) {
|
||||
ctx.throw(401, "Deployment unauthorised")
|
||||
} else {
|
||||
await next()
|
||||
|
|
Loading…
Reference in New Issue