Skip to content

Commit 1bb9465

Browse files
committed
add magic link code and dashboard simulation
1 parent 8e4336c commit 1bb9465

Some content is hidden

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

71 files changed

+8581
-252
lines changed

.editorconfig

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
root = true
2+
3+
[*]
4+
end_of_line = lf
5+
insert_final_newline = true
6+
charset = utf-8
7+
indent_style = space
8+
indent_size = 2
9+
trim_trailing_whitespace = true
10+
11+
[*.{ts,tsx,js,jsx,json,yml,yaml}]
12+
quote_type = single

.env.example

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
APP_NAME=hyperwave
2+
EMAIL_FROM="[email protected]"
3+
HOST=http://localhost:3000
4+
NODE_ENV=development
5+
PORT=3000
6+
RESEND_API_KEY=go_get_an_api_key_from_resend.com
7+
SECRET_KEY=change_this_to_a_secure_random_key_with_32_chars
8+
SKIP_AUTH=false
9+
STORAGE_PROVIDER=local

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,10 @@ package-lock.json
4343

4444
server
4545

46+
# SQLite databases
4647
db.sqlite
48+
app.db
49+
*.db
50+
*.db-shm
51+
*.db-wal
52+
.env

Dockerfile

Lines changed: 7 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,38 +1,18 @@
1-
# use the official Bun image
2-
# see all versions at https://hub.docker.com/r/oven/bun/tags
31
FROM oven/bun:1 AS base
42
WORKDIR /usr/src/app
53

6-
# install dependencies into temp directory
7-
# this will cache them and speed up future builds
84
FROM base AS install
9-
RUN mkdir -p /temp/dev
10-
COPY package.json bun.lockb /temp/dev/
11-
RUN cd /temp/dev && bun install --frozen-lockfile
5+
COPY package.json bun.lock ./
6+
RUN bun install --frozen-lockfile
127

13-
# install
14-
RUN mkdir -p /temp/prod
15-
COPY package.json bun.lockb /temp/prod/
16-
RUN cd /temp/prod && bun install --frozen-lockfile
17-
18-
# copy node_modules from temp directory
19-
# then copy all (non-ignored) project files into the image
20-
FROM base AS prerelease
21-
COPY --from=install /temp/dev/node_modules node_modules
22-
COPY . .
8+
FROM base AS release
9+
COPY --from=install /usr/src/app/node_modules node_modules
10+
COPY . ./
11+
RUN cp .env.example .env
2312

24-
# Env vars
2513
ENV NODE_ENV=production
14+
ENV PORT=3000
2615

27-
# copy production dependencies and source code into final image
28-
FROM base AS release
29-
COPY --from=prerelease /usr/src/app .
30-
COPY --from=install /temp/dev/node_modules node_modules
31-
COPY --from=prerelease /usr/src/app/public public
32-
33-
# run the app
3416
USER bun
3517
EXPOSE 3000/tcp
36-
WORKDIR /usr/src/app
37-
ENV PORT=3000
3818
ENTRYPOINT ["bun", "run", "src/server.tsx"]

0 commit comments

Comments
 (0)