From ea56203a6f45d1769067c682e99a0d3fabec99b3 Mon Sep 17 00:00:00 2001 From: soulgalore Date: Fri, 24 May 2024 08:01:41 +0200 Subject: [PATCH 1/8] more work on the action --- .github/workflows/linux.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index f316a1d..d7729a4 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -10,7 +10,6 @@ jobs: build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 - name: Use Node.js uses: actions/setup-node@v4 with: @@ -19,6 +18,7 @@ jobs: run: | git clone https://github.com/sitespeedio/sitespeed.io.git npm install --prefix sitespeed.io -g + - uses: actions/checkout@v4 - name: Install Chrome run: | wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add - From ddebdca59959ffd0ec306c7fc5c449718edde02e Mon Sep 17 00:00:00 2001 From: soulgalore Date: Fri, 24 May 2024 08:03:48 +0200 Subject: [PATCH 2/8] fix --- .github/workflows/linux.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index d7729a4..51f354c 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -17,7 +17,8 @@ jobs: - name: Install sitespeed.io run: | git clone https://github.com/sitespeedio/sitespeed.io.git - npm install --prefix sitespeed.io -g + cd sitespeed.io + npm install -g - uses: actions/checkout@v4 - name: Install Chrome run: | From a934d6d31af8bad551c1b83eebb59064ad852936 Mon Sep 17 00:00:00 2001 From: soulgalore Date: Fri, 24 May 2024 08:09:43 +0200 Subject: [PATCH 3/8] more fix --- .github/workflows/linux.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 51f354c..91e5438 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -18,7 +18,8 @@ jobs: run: | git clone https://github.com/sitespeedio/sitespeed.io.git cd sitespeed.io - npm install -g + npm install + npm link - uses: actions/checkout@v4 - name: Install Chrome run: | From cb3cf8d7621875cc88cfbb0d04ed74ae0e6b54fc Mon Sep 17 00:00:00 2001 From: soulgalore Date: Fri, 24 May 2024 08:13:49 +0200 Subject: [PATCH 4/8] fix --- .github/workflows/linux.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 91e5438..cb0494c 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -20,6 +20,7 @@ jobs: cd sitespeed.io npm install npm link + echo "::add-path::$(npm bin -g)" - uses: actions/checkout@v4 - name: Install Chrome run: | From 171e9c7c052986b7e18a44182bc3d0e63900fbcd Mon Sep 17 00:00:00 2001 From: soulgalore Date: Fri, 24 May 2024 08:16:13 +0200 Subject: [PATCH 5/8] more fix --- .github/workflows/linux.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index cb0494c..3b2ea4c 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -20,7 +20,7 @@ jobs: cd sitespeed.io npm install npm link - echo "::add-path::$(npm bin -g)" + echo "$(npm bin -g)" >> $GITHUB_PATH - uses: actions/checkout@v4 - name: Install Chrome run: | From bd649ee8731244c4e61f549f38d25a01bdaf7bf4 Mon Sep 17 00:00:00 2001 From: soulgalore Date: Fri, 24 May 2024 08:30:59 +0200 Subject: [PATCH 6/8] last try --- .github/workflows/linux.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 3b2ea4c..62a1a9f 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -21,6 +21,11 @@ jobs: npm install npm link echo "$(npm bin -g)" >> $GITHUB_PATH + npm bin -g | tee -a $GITHUB_ENV + - name: Update PATH + run: echo "PATH=$(npm bin -g):$PATH" >> $GITHUB_ENV + - name: Run sitespeed.io + run: sitespeed.io --version - uses: actions/checkout@v4 - name: Install Chrome run: | From 16f5d96fc549b67eb69ac7cd11b1210504e37476 Mon Sep 17 00:00:00 2001 From: soulgalore Date: Fri, 24 May 2024 08:35:45 +0200 Subject: [PATCH 7/8] kiss --- .github/workflows/linux.yml | 20 ++++++-------------- 1 file changed, 6 insertions(+), 14 deletions(-) diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 62a1a9f..4ad4a3f 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -14,18 +14,6 @@ jobs: uses: actions/setup-node@v4 with: node-version: '20.x' - - name: Install sitespeed.io - run: | - git clone https://github.com/sitespeedio/sitespeed.io.git - cd sitespeed.io - npm install - npm link - echo "$(npm bin -g)" >> $GITHUB_PATH - npm bin -g | tee -a $GITHUB_ENV - - name: Update PATH - run: echo "PATH=$(npm bin -g):$PATH" >> $GITHUB_ENV - - name: Run sitespeed.io - run: sitespeed.io --version - uses: actions/checkout@v4 - name: Install Chrome run: | @@ -44,5 +32,9 @@ jobs: run: | npm install --prefix testrunner node testrunner/app.js & - - name: Add a test - run: sitespeed.io https://www.wikipedia.org -n 1 --api.hostname 127.0.0.1 --api.location default --headless --api.json \ No newline at end of file + - name: Run a test + run: | + git clone https://github.com/sitespeedio/sitespeed.io.git + cd sitespeed.io + npm install + bin/sitespeed.js https://www.wikipedia.org -n 1 --api.hostname 127.0.0.1 --api.location default --headless --api.json \ No newline at end of file From aacadb123779c47b3865292709e96464ae46e738 Mon Sep 17 00:00:00 2001 From: soulgalore Date: Fri, 24 May 2024 09:16:34 +0200 Subject: [PATCH 8/8] tmpdir fix --- testrunner/config/default.yaml | 2 +- testrunner/src/testrunners/testrunner.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/testrunner/config/default.yaml b/testrunner/config/default.yaml index 668e38d..9d386b1 100644 --- a/testrunner/config/default.yaml +++ b/testrunner/config/default.yaml @@ -42,7 +42,7 @@ logging: # The working directory for the testrunner, where it temporary will put it files # By default it used the os.tmpdir -# workingDirectory: "./" +# workingDirectory: "." # The sitespeed.io executable. The default is a globally installed sitespeed.io executable: "sitespeed.io" diff --git a/testrunner/src/testrunners/testrunner.js b/testrunner/src/testrunners/testrunner.js index ccffbdc..6b5f140 100644 --- a/testrunner/src/testrunners/testrunner.js +++ b/testrunner/src/testrunners/testrunner.js @@ -76,7 +76,7 @@ export default async function runJob(job) { async function createWorkingDirectory(job) { const baseWorkingDirectory = nconf.get('workingDirectory') || os.tmpdir(); - const directory = `${baseWorkingDirectory}${job.queue.name}/${job.id}`; + const directory = `${baseWorkingDirectory}/${job.queue.name}/${job.id}`; await mkdir(directory, { recursive: true }); return directory; }