Replies: 18 comments
-
Thanks for filing @bradyma1! This isn't JSON. Are you putting this content into a |
Beta Was this translation helpful? Give feedback.
-
yes. I am guessing I need to use .js and .json more detail... const fs = require('fs'); module.exports = { |
Beta Was this translation helpful? Give feedback.
-
ok..got past that..... starting with lhci@0.6.1 start: Is this still the format... and I am referencing lighthouse.js in the dockerfile.. Also is the run the same now...or do I need more options? |
Beta Was this translation helpful? Give feedback.
-
It kind of like it ignoring my options...as it is not .json....... |
Beta Was this translation helpful? Give feedback.
-
or do I need to convert these to .json.... |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
sorry typo.....hmmmm still coming back with Options...like it is not seeing file..and the help show that .json is read in config. |
Beta Was this translation helpful? Give feedback.
-
actually I used ./lighthouserc.js......but I don't think that matters. |
Beta Was this translation helpful? Give feedback.
-
Alright let's back up several steps then. Here's what an issue needs to have for us to be able to help :)
Example: Steps $ docker run -it --entrypoint /bin/bash node:12-buster
$ npm install @lhci/server @lhci/cli
$ cat > config.json <<EOF
module.exports = {};
EOF
$ ./node_modules/.bin/lhci server --config=./config.json Expected Actual Response to this Example Bug Report |
Beta Was this translation helpful? Give feedback.
-
errno 1 Failed at the lhci@0.6.1 start script unexpected token |
Beta Was this translation helpful? Give feedback.
-
steps from your original example COPY package.json package-lock.json .npmrc lighthouserc.js /app/ ADD static/fonts/roboto .node_modules/@lhci/server/dist all from your original example... RUN sed CMD [ "npm", ":start" ] |
Beta Was this translation helpful? Give feedback.
-
step 1 continued..also from original example with upgrade of lighthouseserver and lhci - package.json |
Beta Was this translation helpful? Give feedback.
-
Step 2 - errors listed above and docker instance does not come up. Other things to note - also did docker volume create lhci-data Excepted result, docker instance to come up... and ssl connect with postgres database |
Beta Was this translation helpful? Give feedback.
-
other info -
|
Beta Was this translation helpful? Give feedback.
-
another hint....even when running the command locally, I am geting the same error..almost like the --config does not recognize .js files |
Beta Was this translation helpful? Give feedback.
-
I'm sorry @bradyma1 but I'm still not clear on what exact steps were taken, what very specific behavior you expect at a particular step, and what behavior happens at that particular step to believe there's a bug here. This information might be sufficient for other forums of helpers to look into but there's not enough here for us to act on with our limited time, so I've converted it to a discussion open to community instead. |
Beta Was this translation helpful? Give feedback.
-
ok......sorry if this is not clear......I am simply trying to convert a docker server instance formerly connecting to postgres non ssl to ssl...using your initial example and substituting the .json example with the new .js example provided above. I cannot get the server to come up and connect to the postgres database in ssl mode with a client certificate or even attempt to connect to the database when using the .js file provided. |
Beta Was this translation helpful? Give feedback.
-
Also, whether attempting to connect to the postgres via the docker instance or via a simple lighthouserc.js.....I command is failing with errno 1 Failed at the lhci@0.6.1 start script unexpected token |
Beta Was this translation helpful? Give feedback.
-
getting Unexpected token c in JSON at position 0 when starting docker instance - with
const fs = require('fs');
module.exports = {
ci: {
server: {
storage: {
storageMethod: 'sql',
sqlDialect: 'postgres',
sqlConnectionSsl: true,
sqlConnectionUrl: process.env.DATABASE_URL,
sqlDialectOptions: {
ssl: {
ca: fs.readFileSync('./certs/ca.crt', 'utf8'),
key: fs.readFileSync('./certs/client.foo.key', 'utf8'),
cert: fs.readFileSync('./certs/client.foo.crt', 'utf8'),
},
},
},
},
},
};
Is this chrome?
Beta Was this translation helpful? Give feedback.
All reactions