From 5fde9e1a1a262ce69992d3151728e39fefe4ffd7 Mon Sep 17 00:00:00 2001 From: Tim van der Lippe Date: Thu, 16 Jul 2020 12:20:18 +0100 Subject: [PATCH 1/3] Add DockerFile for ChromeDevTools Note that I was not able to verify it fully works, as it throws an authentication error on typescript/typescript on the Docker Hub. This is part of #39568 CC @weswigham --- .../chrome-devtools-frontend-next/Dockerfile | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 tests/cases/docker/chrome-devtools-frontend-next/Dockerfile diff --git a/tests/cases/docker/chrome-devtools-frontend-next/Dockerfile b/tests/cases/docker/chrome-devtools-frontend-next/Dockerfile new file mode 100644 index 0000000000000..12dc3a313293e --- /dev/null +++ b/tests/cases/docker/chrome-devtools-frontend-next/Dockerfile @@ -0,0 +1,14 @@ +FROM node:current +RUN git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git /depot_tools +ENV PATH=/depot_tools:$PATH +WORKDIR / +RUN mkdir devtools +WORKDIR devtools +RUN fetch devtools-frontend +WORKDIR devtools-frontend +RUN gn gen out/Default +COPY --from=typescript/typescript /typescript/typescript-*.tgz typescript.tgz +RUN mkdir /typescript +RUN tar -xzvf /typescript.tgz -C /typescript +RUN ln -s /typescript/package ./node_modules/typescript +CMD [ "autoninja", "-C", "out/Default" ] \ No newline at end of file From 6a949bbb449d4f07ba3a52454ad156fe5723157f Mon Sep 17 00:00:00 2001 From: Tim van der Lippe Date: Thu, 16 Jul 2020 12:32:08 +0100 Subject: [PATCH 2/3] Fix run command --- tests/cases/docker/chrome-devtools-frontend-next/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/cases/docker/chrome-devtools-frontend-next/Dockerfile b/tests/cases/docker/chrome-devtools-frontend-next/Dockerfile index 12dc3a313293e..f2dbf2244322e 100644 --- a/tests/cases/docker/chrome-devtools-frontend-next/Dockerfile +++ b/tests/cases/docker/chrome-devtools-frontend-next/Dockerfile @@ -11,4 +11,4 @@ COPY --from=typescript/typescript /typescript/typescript-*.tgz typescript.tgz RUN mkdir /typescript RUN tar -xzvf /typescript.tgz -C /typescript RUN ln -s /typescript/package ./node_modules/typescript -CMD [ "autoninja", "-C", "out/Default" ] \ No newline at end of file +RUN autoninja -C out/Default front_end \ No newline at end of file From 6517bc9b43063474a843efb2cb34f986fae1aac8 Mon Sep 17 00:00:00 2001 From: Tim van der Lippe Date: Thu, 16 Jul 2020 18:54:31 +0100 Subject: [PATCH 3/3] Update run command --- .../cases/docker/chrome-devtools-frontend-next/Dockerfile | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/tests/cases/docker/chrome-devtools-frontend-next/Dockerfile b/tests/cases/docker/chrome-devtools-frontend-next/Dockerfile index f2dbf2244322e..1637eaef7f528 100644 --- a/tests/cases/docker/chrome-devtools-frontend-next/Dockerfile +++ b/tests/cases/docker/chrome-devtools-frontend-next/Dockerfile @@ -7,8 +7,11 @@ WORKDIR devtools RUN fetch devtools-frontend WORKDIR devtools-frontend RUN gn gen out/Default -COPY --from=typescript/typescript /typescript/typescript-*.tgz typescript.tgz +COPY --from=typescript/typescript /typescript/typescript-*.tgz /typescript.tgz RUN mkdir /typescript RUN tar -xzvf /typescript.tgz -C /typescript RUN ln -s /typescript/package ./node_modules/typescript -RUN autoninja -C out/Default front_end \ No newline at end of file +# We don't want to show the ordering of which tasks ran in Ninja, as that is non-deterministic. +# Instead, only show the errors in the log, from the first occurrence of a FAILED task. +# If the task passes, then there is no log written. +CMD ["autoninja", "-C", "out/Default", ">", "error.log", "||", "tail", "-n", "+$(sed", "-n", "'/FAILED/='", "error.log)", "error.log"] \ No newline at end of file