This commit is contained in:
Peter Clement 2024-03-25 16:42:03 +00:00
parent 39cd39ebf5
commit c068ed9200
2 changed files with 3 additions and 4 deletions

View File

@ -11,7 +11,7 @@ class ObjectStoreWaitStrategy extends AbstractWaitStrategy {
}
}
export async function start(): Promise<{ host: string; port: number }> {
export async function start(): Promise<void> {
container = await new GenericContainer("minio/minio")
.withExposedPorts(9000)
.withCommand(["server", "/data"])
@ -22,10 +22,8 @@ export async function start(): Promise<{ host: string; port: number }> {
.withWaitStrategy(new ObjectStoreWaitStrategy().withStartupTimeout(30000))
.start()
const host = container.getHost()
const port = container.getMappedPort(9000)
env._set("MINIO_URL", `http:/${host}:${port}`)
return { host, port }
env._set("MINIO_URL", `http://0.0.0.0:${port}`)
}
export async function stop() {

View File

@ -5,6 +5,7 @@ import { EmailTemplatePurpose } from "../../../../constants"
import { objectStoreTestProviders, mocks } from "@budibase/backend-core/tests"
import { objectStore } from "@budibase/backend-core"
import tk from "timekeeper"
const nodemailer = require("nodemailer")
const fetch = require("node-fetch")