Quantcast
Channel: Grafana k6 - Grafana Labs Community Forums
Viewing all articles
Browse latest Browse all 339

Cannot run k6 docker image that was built from windows on linux: lanching browser error - no such file or directory

$
0
0

Hi, all

I have developed all the k6 scripts and build the docker image via Dockerfile on on the windows using WSL.

Here is my Dockerfile

FROM grafana/k6:0.55.0

RUN apk update && apk add --no-cache chromium

ENV K6_BROWSER_ENABLED=true

USER k6

COPY config.js /config.js
COPY setup.js /setup.js
COPY metrics.js /metrics.js
COPY script.js /script.js
COPY data.json /data.json

CMD ["run", "/script.js"]

Yes, what I did is copying all script files to the image and trying to build it as image and run the test from it.

When I run the docker image on the windows for testing. It works very well.

However, when I load this docker image on the linux instance (Alibaba Linux 3), it doesn’t work at all, not even start the test but return this error instead:

error building browser on IterStart: launching browser: open /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq: No such file or directory (2) at default (file:///[js file name]:xx:xx(x))

Not sure what’s wrong with the browser test on the image, but I hope someone can figure out how to get through from this error.

Thank you.

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 339

Trending Articles