Skip to content

Commit a07b8a6

Browse files
mxkaskeclaude
andauthored
revert: roll back Deno build migration (#2323-#2326) (#2328)
Reverts the Deno build migration and its Railway build follow-up fixes, restoring the server and workflows apps to the prior Bun/Node toolchain. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
1 parent f0d315e commit a07b8a6

534 files changed

Lines changed: 3125 additions & 5066 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/check.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

.github/workflows/dx.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,10 +41,10 @@ jobs:
4141
- name: 📥 Download deps
4242
run: pnpm install
4343

44-
- name: 🦕 Setup Deno
45-
uses: denoland/setup-deno@v2
44+
- name: 🔥 Install bun
45+
uses: oven-sh/setup-bun@v2
4646
with:
47-
deno-version: v2.x
47+
bun-version: latest
4848

4949
- name: 🔥 DX task
5050
run: pnpm dx

.github/workflows/test.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,18 +30,18 @@ jobs:
3030
uses: actions/checkout@v6
3131

3232
- name: Set up pnpm
33-
uses: pnpm/action-setup@v6
33+
uses: pnpm/action-setup@v4
3434

3535
- name: ⎔ Setup node
3636
uses: actions/setup-node@v6
3737
with:
3838
node-version: 24
3939
cache: "pnpm"
4040

41-
- name: 🦕 Setup Deno
42-
uses: denoland/setup-deno@v2
41+
- name: 🔥 Install bun
42+
uses: oven-sh/setup-bun@v2
4343
with:
44-
deno-version: v2.x
44+
bun-version: latest
4545

4646
- name: 📥 Download deps
4747
run: pnpm install

apps/dashboard/env.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
await Deno.copyFile("./.env.example", "./.env");
1+
const file = Bun.file("./.env.example");
2+
await Bun.write("./.env", file);

apps/screenshot-service/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
"name": "@openstatus/screenshot-service",
33
"version": "0.0.1",
44
"scripts": {
5-
"check": "deno check --sloppy-imports .",
65
"dev": "bun run --hot src/index.ts",
76
"start": "NODE_ENV=production bun run src/index.ts"
87
},

apps/server/.gitignore

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1 @@
11
node_modules
2-
app
3-
src/_serve.bundle.mjs
4-
.deno_compile_bundle_*.mjs
5-
app.tmp-*

apps/server/Dockerfile

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
# See https://github.com/lenra-io/dofigen
44

55
# install
6-
FROM node@sha256:b31e7a42fdf8b8aa5f5ed477c72d694301273f1069c5a2f71d53c6482e99a2fc AS install
6+
FROM node@sha256:242549cd46785b480c832479a730f4f2a20865d61ea2e404fdb2a5c3d3b73ecf AS install
77
LABEL \
8-
org.opencontainers.image.base.digest="sha256:b31e7a42fdf8b8aa5f5ed477c72d694301273f1069c5a2f71d53c6482e99a2fc" \
8+
org.opencontainers.image.base.digest="sha256:242549cd46785b480c832479a730f4f2a20865d61ea2e404fdb2a5c3d3b73ecf" \
99
org.opencontainers.image.base.name="docker.io/node:24-slim" \
1010
org.opencontainers.image.stage="install"
1111
WORKDIR /app/
@@ -48,14 +48,14 @@ RUN \
4848
--mount=type=cache,target=/root/.local/share/pnpm/store,sharing=locked \
4949
<<EOF
5050
corepack enable pnpm
51-
pnpm install --prod --frozen-lockfile --filter=@openstatus/server... --verbose
51+
pnpm install --prod --frozen-lockfile --verbose
5252
EOF
5353

5454
# build
55-
FROM denoland/deno@sha256:8d24854de78a79c56e74b49aa4c5996c60e1fe3730efba8fbdd2692c582e6e29 AS build
55+
FROM oven/bun@sha256:0733e50325078969732ebe3b15ce4c4be5082f18c4ac1a0f0ca4839c2e4e42a7 AS build
5656
LABEL \
57-
org.opencontainers.image.base.digest="sha256:8d24854de78a79c56e74b49aa4c5996c60e1fe3730efba8fbdd2692c582e6e29" \
58-
org.opencontainers.image.base.name="docker.io/denoland/deno:2.9.0" \
57+
org.opencontainers.image.base.digest="sha256:0733e50325078969732ebe3b15ce4c4be5082f18c4ac1a0f0ca4839c2e4e42a7" \
58+
org.opencontainers.image.base.name="docker.io/oven/bun:1.3.11" \
5959
org.opencontainers.image.stage="build"
6060
ENV NODE_ENV="production"
6161
WORKDIR /app/apps/server
@@ -74,17 +74,15 @@ COPY \
7474
--from=install \
7575
--link \
7676
"/app/packages" "/app/packages"
77-
RUN <<EOF
78-
deno bundle --platform=deno --minify --sloppy-imports --node-modules-dir=manual --output src/_serve.bundle.mjs src/serve.ts
79-
deno compile --no-check -A --node-modules-dir=none --include static/openapi.yaml --include static/openapi-v1.json --output app src/_serve.bundle.mjs
80-
EOF
77+
RUN bun build --compile --sourcemap src/index.ts --outfile=app
8178

8279
# runtime
83-
FROM registry.access.redhat.com/hi/curl@sha256:848b81ab5d5e55371d7193fd4f1ea7b605d14dbb039344ffad34a4c1f0d880f4 AS runtime
80+
FROM debian@sha256:cd1bc32f233a49f1b82149c9edb8ef34fb1e6c45f37211445c51a97603468604 AS runtime
8481
LABEL \
8582
io.dofigen.version="2.8.0" \
8683
org.opencontainers.image.authors="OpenStatus Team" \
87-
org.opencontainers.image.base.digest="sha256:848b81ab5d5e55371d7193fd4f1ea7b605d14dbb039344ffad34a4c1f0d880f4" \
84+
org.opencontainers.image.base.digest="sha256:cd1bc32f233a49f1b82149c9edb8ef34fb1e6c45f37211445c51a97603468604" \
85+
org.opencontainers.image.base.name="docker.io/debian:bullseye-slim" \
8886
org.opencontainers.image.description="REST API server with Hono framework for OpenStatus" \
8987
org.opencontainers.image.source="https://github.com/openstatusHQ/openstatus" \
9088
org.opencontainers.image.title="OpenStatus Server" \
@@ -95,12 +93,18 @@ COPY \
9593
--chmod=555 \
9694
--link \
9795
"/app/apps/server/app" "/bin/"
96+
USER 0:0
97+
RUN <<EOF
98+
apt-get update
99+
apt-get install -y --no-install-recommends curl
100+
rm -rf /var/lib/apt/lists/*
101+
EOF
98102
USER 1000:1000
99103
EXPOSE 3000
100104
HEALTHCHECK \
101105
--interval=30s \
102106
--timeout=10s \
103107
--start-period=30s \
104108
--retries=3 \
105-
CMD ["curl", "-f", "http://localhost:3000/ping"]
109+
CMD curl -f http://localhost:3000/ping || exit 1
106110
ENTRYPOINT ["/bin/app"]

apps/server/bunfig.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[test]
2+
preload = ["./src/libs/test/preload.ts"]

apps/server/deno.jsonc

Lines changed: 0 additions & 6 deletions
This file was deleted.

apps/server/docker-compose.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,3 @@ services:
88
- 3000:3000
99
image: server
1010
command: .
11-
env_file:
12-
- ../../.env.docker

0 commit comments

Comments
 (0)