Skip to content

Commit

Permalink
feat: add support for executing wasm plugin from a container registry…
Browse files Browse the repository at this point in the history
… (ghcr.io, gcr.io, azurecr.io)
  • Loading branch information
tsirysndr committed Jul 26, 2024
1 parent 553431e commit f36f397
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/cmd/run.ts
Original file line number Diff line number Diff line change
Expand Up @@ -531,7 +531,13 @@ const saveRepositoryMetadata = async (id: string) => {
};

const runWasmPlugin = async (pipeline: string, job: string[], cwd = ".") => {
if (pipeline.endsWith(".wasm") || pipeline.endsWith("?wasm=1")) {
if (
pipeline.endsWith(".wasm") ||
pipeline.endsWith("?wasm=1") ||
pipeline.startsWith("azurecr.io/") ||
pipeline.startsWith("ghcr.io/") ||
pipeline.startsWith("gcr.io/")
) {
const command = new Deno.Command("bash", {
args: ["-c", `fluentci-engine call -m ${pipeline} -- ` + job.join(" ")],
stdout: "inherit",
Expand Down

0 comments on commit f36f397

Please sign in to comment.