Files
services/examples/function/deploy/node/deployAFunction.js

17 lines
433 B
JavaScript
Executable File

import * as fx from "m3o/function";
// Deploy a group of functions
async function DeployAfunction() {
let functionService = new fx.FunctionService(process.env.MICRO_API_TOKEN);
let rsp = await functionService.deploy({
entrypoint: "helloworld",
name: "my-first-func",
project: "tests",
repo: "github.com/m3o/nodejs-function-example",
runtime: "nodejs14",
});
console.log(rsp);
}
await DeployAfunction();