[READ-ONLY] Mirror of https://github.com/thoda-dev/shhh. Self-hostable zero-knowledge pastebin for secrets that expire on their own
docker end-to-end-encryption nuxt nuxtjs pastebin secrets selft-hosted zero-knowledge
Something went wrong. Try again.
1234567891011121314151617181920import { spawn } from 'node:child_process'import { fileURLToPath } from 'node:url'import { dirname, resolve } from 'node:path'import { wrapWithInfisical } from './infisical.mjs'
const repoRoot = resolve(dirname(fileURLToPath(import.meta.url)), '..')const appDir = resolve(repoRoot, 'apps/app')
export function runAppBin(binRelativePath, args, { env } = {}) { const bin = resolve(appDir, binRelativePath) const { command, args: spawnArgs } = wrapWithInfisical(process.execPath, [bin, ...args], repoRoot)
const child = spawn(command, spawnArgs, { cwd: appDir, stdio: 'inherit', env: { ...process.env, ...env } }) child.on('exit', code => process.exit(code ?? 0))}