mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-13 10:59:39 +00:00
fix(docker): avoid external Dockerfile frontend pull
Signed-off-by: sallyom <somalley@redhat.com>
This commit is contained in:
parent
9677da3dd6
commit
e1795256d5
3 changed files with 8 additions and 4 deletions
|
|
@ -1,5 +1,3 @@
|
|||
# syntax=docker/dockerfile:1.7
|
||||
|
||||
# Opt-in plugin dependencies at build time (space- or comma-separated directory names).
|
||||
# Example: docker build --build-arg OPENCLAW_EXTENSIONS="diagnostics-otel,matrix" .
|
||||
#
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
# syntax=docker/dockerfile:1.7
|
||||
|
||||
FROM debian:bookworm-slim@sha256:f9c6a2fd2ddbc23e336b6257a5245e31f996953ef06cd13a59fa0a1df2d5c252
|
||||
|
||||
ENV DEBIAN_FRONTEND=noninteractive
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ import YAML from "yaml";
|
|||
|
||||
const repoRoot = resolve(fileURLToPath(new URL(".", import.meta.url)), "..");
|
||||
const dockerfilePath = join(repoRoot, "Dockerfile");
|
||||
const dockerSetupDockerfilePaths = ["Dockerfile", "scripts/docker/sandbox/Dockerfile"] as const;
|
||||
const pnpmWorkspacePath = join(repoRoot, "pnpm-workspace.yaml");
|
||||
|
||||
function collapseDockerContinuations(dockerfile: string): string {
|
||||
|
|
@ -14,6 +15,13 @@ function collapseDockerContinuations(dockerfile: string): string {
|
|||
}
|
||||
|
||||
describe("Dockerfile", () => {
|
||||
it("does not force an external Dockerfile frontend pull", async () => {
|
||||
for (const path of dockerSetupDockerfilePaths) {
|
||||
const dockerfile = await readFile(join(repoRoot, path), "utf8");
|
||||
expect(dockerfile, path).not.toMatch(/^#\s*syntax=/m);
|
||||
}
|
||||
});
|
||||
|
||||
it("uses full bookworm for build stages and slim bookworm for runtime", async () => {
|
||||
const dockerfile = await readFile(dockerfilePath, "utf8");
|
||||
expect(dockerfile).toContain(
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue