server: Read local package.json as opposed to the one in the runner folder
continuous-integration/appveyor/branch AppVeyor build succeeded Details

master
Jonatan Nilsson 2022-03-12 22:33:28 +00:00
parent 2a18df18ba
commit 4dab6ea05d
1 changed files with 3 additions and 3 deletions

View File

@ -1,9 +1,9 @@
import path from 'path'
import { readFileSync } from 'fs'
import { fileURLToPath } from 'url'
import { Util } from 'service-core'
export function run(http, orgPort, ctx) {
let packagePath = ctx.util.getPathFromRoot('./package.json')
let localUtil = new Util(import.meta.url)
let packagePath = localUtil.getPathFromRoot('../package.json')
let packageInfo = JSON.parse(readFileSync(packagePath))
const server = http.createServer(function (req, res) {