Skip to content
This repository was archived by the owner on Jan 7, 2025. It is now read-only.

Commit 916c7e0

Browse files
committed
更新 Dockerfile 中的基础镜像,修改 docker-compose.yml 使用 PostgreSQL 15-alpine,添加动态导出到 API 路由文件,清理代码注释
1 parent 91431fe commit 916c7e0

File tree

6 files changed

+1389
-1183
lines changed

6 files changed

+1389
-1183
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM node:current-alpine as base
1+
FROM node:current-alpine AS base
22

33
RUN apk add --no-cache libc6-compat
44

app/api/Categories/route.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
import { IPill } from "@/Components/Pill";
22
import { prisma } from "..";
33

4+
export const dynamic = 'force-dynamic';
5+
46
/**
5-
*
6-
*
77
* @author Aloento
88
* @since 0.1.0
99
* @version 0.1.0

app/api/Statistics/route.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
1-
import { IStatistics } from '@/Components/PersonCard'
2-
import { prisma } from '..'
1+
import { IStatistics } from '@/Components/PersonCard';
2+
import { prisma } from '..';
3+
4+
export const dynamic = 'force-dynamic';
35

46
/**
57
* @author Aloento

app/page.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@ import { useRequest } from "ahooks";
55
import { PostCard } from "../Components/PostCard";
66

77
/**
8-
*
9-
*
108
* @author Aloento
119
* @since 0.1.0
1210
* @version 0.1.0

docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ version: "3.8"
22

33
services:
44
db:
5-
image: postgres:alpine
5+
image: postgres:15-alpine
66
environment:
77
POSTGRES_USER: postgres
88
POSTGRES_PASSWORD: postgres

0 commit comments

Comments
 (0)