Docker build updates
This commit is contained in:
parent
3e36aef9c5
commit
67a5b60ad5
34 changed files with 89 additions and 52 deletions
26
apps/bridge-worker/index.ts
Normal file
26
apps/bridge-worker/index.ts
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
import { run } from "graphile-worker";
|
||||
import * as path from "path";
|
||||
import { fileURLToPath } from "url";
|
||||
|
||||
const __filename = fileURLToPath(import.meta.url);
|
||||
const __dirname = path.dirname(__filename);
|
||||
|
||||
const startWorker = async () => {
|
||||
await run({
|
||||
connectionString: process.env.DATABASE_URL,
|
||||
concurrency: 10,
|
||||
noHandleSignals: false,
|
||||
pollInterval: 1000,
|
||||
taskDirectory: `${__dirname}/tasks`,
|
||||
// crontabFile: `${__dirname}/crontab`,
|
||||
});
|
||||
};
|
||||
|
||||
const main = async () => {
|
||||
await startWorker();
|
||||
};
|
||||
|
||||
main().catch((err) => {
|
||||
console.error(err);
|
||||
process.exit(1);
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue