From 10753c48adecc53d502b486a5431b7fc5a41ee27 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0tefan=20Baebler?= Date: Sat, 31 Aug 2024 19:08:24 +0200 Subject: [PATCH 1/9] Browserslist update npx browserslist@latest --update-db --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 6b472c8a6..7fa6d8dbc 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3479,9 +3479,9 @@ caniuse-api@^3.0.0: lodash.uniq "^4.5.0" caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001109, caniuse-lite@^1.0.30001286, caniuse-lite@^1.0.30001359: - version "1.0.30001473" - resolved "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001473.tgz" - integrity sha512-ewDad7+D2vlyy+E4UJuVfiBsU69IL+8oVmTuZnH5Q6CIUbxNfI50uVpRHbUPDD6SUaN2o0Lh4DhTrvLG/Tn1yg== + version "1.0.30001655" + resolved "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001655.tgz" + integrity sha512-jRGVy3iSGO5Uutn2owlb5gR6qsGngTw9ZTb4ali9f3glshcNmJ2noam4Mo9zia5P9Dk3jNNydy7vQjuE5dQmfg== capture-exit@^2.0.0: version "2.0.0" From 7fabe56d5d71cbafaa3dff100e16cc44562356ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0tefan=20Baebler?= Date: Mon, 1 Jan 2024 22:24:03 +0100 Subject: [PATCH 2/9] net8.0 --- tests/Visualizations.Tests/Visualizations.Tests.fsproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Visualizations.Tests/Visualizations.Tests.fsproj b/tests/Visualizations.Tests/Visualizations.Tests.fsproj index 2be236c9c..b8727321e 100644 --- a/tests/Visualizations.Tests/Visualizations.Tests.fsproj +++ b/tests/Visualizations.Tests/Visualizations.Tests.fsproj @@ -1,7 +1,7 @@ - netcoreapp3.1 + net8.0 false false From a1adaff97528df4a63510b4884b74308d07827d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0tefan=20Baebler?= Date: Mon, 1 Jan 2024 22:32:22 +0100 Subject: [PATCH 3/9] 2 more projects to net8.0 --- Owid.Analyzer/Owid.Analyzer.fsproj | 2 +- src/visualizations/App.fsproj | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Owid.Analyzer/Owid.Analyzer.fsproj b/Owid.Analyzer/Owid.Analyzer.fsproj index 05bd28586..065b40736 100644 --- a/Owid.Analyzer/Owid.Analyzer.fsproj +++ b/Owid.Analyzer/Owid.Analyzer.fsproj @@ -2,7 +2,7 @@ Exe - netcoreapp3.1 + net8.0 diff --git a/src/visualizations/App.fsproj b/src/visualizations/App.fsproj index bebc3838a..32010e7fe 100644 --- a/src/visualizations/App.fsproj +++ b/src/visualizations/App.fsproj @@ -1,6 +1,6 @@ - netcoreapp3.0 + net8.0 From 6b65dc28c9251b32eb1ea2bb852fc7a7058362b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0tefan=20Baebler?= Date: Mon, 1 Jan 2024 22:43:51 +0100 Subject: [PATCH 4/9] test: ubuntu-latest --- .github/workflows/pr.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 4a74fd505..2bd055ac5 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -15,7 +15,7 @@ env: jobs: test: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest steps: - name: Debug uses: hmarr/debug-action@v2.1.0 From b7cfc8cd117eebbcaeb2c1454c99791fff5f3cee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0tefan=20Baebler?= Date: Mon, 1 Jan 2024 22:47:08 +0100 Subject: [PATCH 5/9] test: node 20 --- .github/workflows/pr.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 2bd055ac5..e48447287 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/setup-node@v3.6.0 with: - node-version: '18' + node-version: '20' - name: Get yarn cache directory path id: yarn-cache-dir-path From a7fea617cf7b704f3f1b53db82d1afdd0411f1b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0tefan=20Baebler?= Date: Mon, 1 Jan 2024 22:53:37 +0100 Subject: [PATCH 6/9] test: downgrade node to 18 https://nodejs.org/en/about/previous-releases --- .github/workflows/pr.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index e48447287..2bd055ac5 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/setup-node@v3.6.0 with: - node-version: '20' + node-version: '18' - name: Get yarn cache directory path id: yarn-cache-dir-path From 5773e7e9353d3882a32d971787269567816c0651 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0tefan=20Baebler?= Date: Tue, 2 Jan 2024 08:11:35 +0100 Subject: [PATCH 7/9] ubuntu-latest --- .github/workflows/pr-cleanup.yml | 2 +- .github/workflows/pr.yml | 4 ++-- .github/workflows/prod.yml | 6 +++--- .github/workflows/stage.yml | 6 +++--- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/pr-cleanup.yml b/.github/workflows/pr-cleanup.yml index 5dae28dcb..0920b3449 100644 --- a/.github/workflows/pr-cleanup.yml +++ b/.github/workflows/pr-cleanup.yml @@ -26,7 +26,7 @@ jobs: has_label: ${{ steps.label.outputs.has_label }} undeploy: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest needs: [check] if: "needs.check.status_code != '404' && (github.event.action == 'closed' || !needs.check.has_label)" steps: diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 2bd055ac5..0089e36ce 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -48,7 +48,7 @@ jobs: build: if: contains(github.event.pull_request.labels.*.name, 'deploy-preview') needs: test - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest steps: - name: Checkout repo uses: actions/checkout@v4 @@ -75,7 +75,7 @@ jobs: BUILD_MODE=staging deploy: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest if: contains(github.event.pull_request.labels.*.name, 'deploy-preview') needs: build steps: diff --git a/.github/workflows/prod.yml b/.github/workflows/prod.yml index 972018065..669180d50 100644 --- a/.github/workflows/prod.yml +++ b/.github/workflows/prod.yml @@ -14,7 +14,7 @@ env: jobs: test: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest steps: - name: Debug uses: hmarr/debug-action@v2.1.0 @@ -32,7 +32,7 @@ jobs: # - run: yarn test-fsharp build: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest needs: test steps: - name: Checkout repo @@ -60,7 +60,7 @@ jobs: BUILD_MODE=production deploy: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest needs: build steps: - name: Checkout repo diff --git a/.github/workflows/stage.yml b/.github/workflows/stage.yml index e776d9e01..56f959952 100644 --- a/.github/workflows/stage.yml +++ b/.github/workflows/stage.yml @@ -14,7 +14,7 @@ env: jobs: test: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest steps: - name: Debug uses: hmarr/debug-action@v2.1.0 @@ -45,7 +45,7 @@ jobs: # - run: yarn test-fsharp build: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest needs: test if: "!contains(github.event.head_commit.message, 'NOBUILD')" steps: @@ -74,7 +74,7 @@ jobs: BUILD_MODE=staging deploy: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest needs: build if: "!contains(github.event.head_commit.message, 'NODEPLOY')" steps: From 75918cb029c3d31c6fe362cb7c86ac71660cad83 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0tefan=20Baebler?= Date: Tue, 2 Jan 2024 09:04:29 +0100 Subject: [PATCH 8/9] Dockerfile: .net 8, node 18 --- Dockerfile | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 4aec3d6be..e8ea22d6c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,10 +1,20 @@ ######################################## # Intermediate builder image (used only for build, discarded in final stage) ######################################## -FROM ghcr.io/sledilnik/website-base AS builder +FROM bitnami/dotnet-sdk:8-debian-11 as builder +ARG NODE_MAJOR=18 + +WORKDIR /app ARG BUILD_MODE=production +RUN apt-get update && apt-get install -y ca-certificates curl gnupg && mkdir -p /etc/apt/keyrings && \ + curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg; + +RUN echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" > /etc/apt/sources.list.d/nodesource.list; + +RUN apt-get update && apt-get install nodejs -y && npm install --global yarn + ADD . /app RUN yarn RUN CADDY_BUILD=1 yarn build --mode ${BUILD_MODE} From e11cd233079ecaab72c631249a944dedb2bf25aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0tefan=20Baebler?= Date: Tue, 2 Jan 2024 11:09:19 +0100 Subject: [PATCH 9/9] bump webpack for node 18 --- yarn.lock | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/yarn.lock b/yarn.lock index 7fa6d8dbc..400048d76 100644 --- a/yarn.lock +++ b/yarn.lock @@ -12216,10 +12216,10 @@ webpack-sources@^3.2.3: resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-3.2.3.tgz#2d4daab8451fd4b240cc27055ff6a0c2ccea0cde" integrity sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w== -webpack@^4.0.0: - version "4.46.0" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.46.0.tgz#bf9b4404ea20a073605e0a011d188d77cb6ad542" - integrity sha512-6jJuJjg8znb/xRItk7bkT0+Q7AHCYjjFnvKIWQPkNIOyRqoCGvkOs0ipeQzrqz4l5FtN5ZI/ukEHroeX/o1/5Q== +"webpack@>=4.47.0 <5": + version "4.47.0" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.47.0.tgz#8b8a02152d7076aeb03b61b47dad2eeed9810ebc" + integrity sha512-td7fYwgLSrky3fI1EuU5cneU4+pbH6GgOfuKNS1tNPcfdGinGELAqsb/BP4nnvZyKSG2i/xFGU7+n2PvZA8HJQ== dependencies: "@webassemblyjs/ast" "1.9.0" "@webassemblyjs/helper-module-context" "1.9.0" @@ -12245,7 +12245,7 @@ webpack@^4.0.0: watchpack "^1.7.4" webpack-sources "^1.4.1" -webpack@^5.54.0: +webpack@^5.61.0: version "5.73.0" resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.73.0.tgz#bbd17738f8a53ee5760ea2f59dce7f3431d35d38" integrity sha512-svjudQRPPa0YiOYa2lM/Gacw0r6PvxptHj4FuEKQ2kX05ZLkjbVc5MnPs6its5j7IZljnIqSVo/OsY2X0IpHGA==