Merge branch 'master' into fix/rm-plan-business
This commit is contained in:
commit
2586407189
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"version": "2.13.43",
|
||||
"version": "2.13.44",
|
||||
"npmClient": "yarn",
|
||||
"packages": [
|
||||
"packages/*",
|
||||
|
|
|
@ -68,9 +68,13 @@ COPY packages/server/builder/ builder/
|
|||
COPY packages/server/client/ client/
|
||||
|
||||
ARG BUDIBASE_VERSION
|
||||
ARG GIT_COMMIT_SHA
|
||||
# Ensuring the version argument is sent
|
||||
RUN test -n "$BUDIBASE_VERSION"
|
||||
ENV BUDIBASE_VERSION=$BUDIBASE_VERSION
|
||||
ENV DD_GIT_REPOSITORY_URL=https://github.com/budibase/budibase
|
||||
ENV DD_GIT_COMMIT_SHA=$GIT_COMMIT_SHA
|
||||
ENV DD_VERSION=$BUDIBASE_VERSION
|
||||
|
||||
EXPOSE 4001
|
||||
|
||||
|
|
|
@ -56,6 +56,10 @@ module.exports.processJS = (handlebars, context) => {
|
|||
const res = { data: runJS(js, sandboxContext) }
|
||||
return `{{${LITERAL_MARKER} js_result-${JSON.stringify(res)}}}`
|
||||
} catch (error) {
|
||||
console.log(`JS error: ${typeof error} ${JSON.stringify(error)}`)
|
||||
if (error.code === "ERR_SCRIPT_EXECUTION_TIMEOUT") {
|
||||
return "Timed out while executing JS"
|
||||
}
|
||||
return "Error while executing JS"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -114,7 +114,7 @@ describe("Test the JavaScript helper", () => {
|
|||
|
||||
it("should timeout after one second", () => {
|
||||
const output = processJS(`while (true) {}`)
|
||||
expect(output).toBe("Error while executing JS")
|
||||
expect(output).toBe("Timed out while executing JS")
|
||||
})
|
||||
|
||||
it("should prevent access to the process global", () => {
|
||||
|
|
|
@ -51,8 +51,12 @@ ENV TENANT_FEATURE_FLAGS=*:LICENSING,*:USER_GROUPS,*:ONBOARDING_TOUR
|
|||
ENV ACCOUNT_PORTAL_URL=https://account.budibase.app
|
||||
|
||||
ARG BUDIBASE_VERSION
|
||||
ARG GIT_COMMIT_SHA
|
||||
# Ensuring the version argument is sent
|
||||
RUN test -n "$BUDIBASE_VERSION"
|
||||
ENV BUDIBASE_VERSION=$BUDIBASE_VERSION
|
||||
ENV DD_GIT_REPOSITORY_URL=https://github.com/budibase/budibase
|
||||
ENV DD_GIT_COMMIT_SHA=$GIT_COMMIT_SHA
|
||||
ENV DD_VERSION=$BUDIBASE_VERSION
|
||||
|
||||
CMD ["./docker_run.sh"]
|
||||
|
|
Loading…
Reference in New Issue