Skip to content

Commit ae6e400

Browse files
committed
feat: init project
0 parents  commit ae6e400

File tree

104 files changed

+12665
-0
lines changed

Some content is hidden

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

104 files changed

+12665
-0
lines changed

.env.prod

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
SERVER_PORT: 8080
2+
3+
POSTGRES_HOST: postgres
4+
POSTGRES_PORT: 5432
5+
POSTGRES_USER: root
6+
POSTGRES_PASSWORD: 123456
7+
POSTGRES_DATABASE: album
8+
9+
ALBUM_PATH: /home/images
10+
11+
HOST_NAME: http://192.168.31.149:8080
12+
PROXY_URL: http://192.168.31.149:7890
13+
14+
15+

.eslintrc.js

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
module.exports = {
2+
parser: '@typescript-eslint/parser',
3+
parserOptions: {
4+
project: 'tsconfig.json',
5+
tsconfigRootDir: __dirname,
6+
sourceType: 'module',
7+
},
8+
plugins: ['@typescript-eslint/eslint-plugin'],
9+
extends: [
10+
'plugin:@typescript-eslint/recommended',
11+
'plugin:prettier/recommended',
12+
],
13+
root: true,
14+
env: {
15+
node: true,
16+
jest: true,
17+
},
18+
ignorePatterns: ['.eslintrc.js'],
19+
rules: {
20+
'@typescript-eslint/interface-name-prefix': 'off',
21+
'@typescript-eslint/explicit-function-return-type': 'off',
22+
'@typescript-eslint/explicit-module-boundary-types': 'off',
23+
'@typescript-eslint/no-explicit-any': 'off',
24+
},
25+
};

.gitignore

+56
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
# compiled output
2+
/dist
3+
/node_modules
4+
/build
5+
6+
# Logs
7+
logs
8+
*.log
9+
npm-debug.log*
10+
pnpm-debug.log*
11+
yarn-debug.log*
12+
yarn-error.log*
13+
lerna-debug.log*
14+
15+
# OS
16+
.DS_Store
17+
18+
# Tests
19+
/coverage
20+
/.nyc_output
21+
22+
# IDEs and editors
23+
/.idea
24+
.project
25+
.classpath
26+
.c9/
27+
*.launch
28+
.settings/
29+
*.sublime-workspace
30+
31+
# IDE - VSCode
32+
.vscode/*
33+
!.vscode/settings.json
34+
!.vscode/tasks.json
35+
!.vscode/launch.json
36+
!.vscode/extensions.json
37+
38+
# dotenv environment variable files
39+
.env
40+
.env.development.local
41+
.env.test.local
42+
.env.production.local
43+
.env.local
44+
45+
# temp directory
46+
.temp
47+
.tmp
48+
49+
# Runtime data
50+
pids
51+
*.pid
52+
*.seed
53+
*.pid.lock
54+
55+
# Diagnostic reports (https://nodejs.org/api/report.html)
56+
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

.prettierrc

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"singleQuote": true,
3+
"trailingComma": "all"
4+
}

Dockerfile

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
FROM node:latest
2+
3+
RUN mkdir -p /app
4+
5+
WORKDIR /app
6+
7+
COPY . ./
8+
9+
RUN rm -rf /app/node_modules && rm -rf /app/dist && npm install && npm run build
10+
11+
CMD npm run start:prod
12+
13+
EXPOSE 8080

README.md

+73

build.sh

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
docker-compose build --no-cache chat-album && docker-compose up -d chat-album
2+
#docker-compose build --no-cache postgres chat-album && docker-compose up -d postgres chat-album

docker-compose.yml

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
services:
2+
postgres:
3+
image: pgvector/pgvector:pg16
4+
environment:
5+
POSTGRES_USER: root
6+
POSTGRES_PASSWORD: 123456
7+
POSTGRES_DB: album
8+
ports:
9+
- "5432:5432"
10+
volumes:
11+
- ./sql/project.sql:/docker-entrypoint-initdb.d/init.sql
12+
- /tmp/postgres/data:/var/lib/postgresql/data
13+
chat-album:
14+
depends_on:
15+
- postgres
16+
build:
17+
context: .
18+
dockerfile: Dockerfile
19+
restart: on-failure
20+
tty: true
21+
ports:
22+
- "8080:8080"
23+
env_file:
24+
- .env.prod
25+
environment:
26+
- OPENAI_API_KEY=${OPENAI_API_KEY}
27+
- ANTHROPIC_API_KEY=${ANTHROPIC_API_KEY}
28+
volumes:
29+
- ./images:/home/images

images/aeroplane-1.avif

22.1 KB
Binary file not shown.

images/aeroplane-10.avif

132 KB
Binary file not shown.

images/aeroplane-2.avif

18 KB
Binary file not shown.

images/aeroplane-3.avif

23.2 KB
Binary file not shown.

images/aeroplane-4.avif

15 KB
Binary file not shown.

images/aeroplane-5.avif

22.3 KB
Binary file not shown.

images/aeroplane-6.avif

13.8 KB
Binary file not shown.

images/aeroplane-7.avif

21.6 KB
Binary file not shown.

images/aeroplane-8.avif

41.7 KB
Binary file not shown.

images/aeroplane-9.avif

22.5 KB
Binary file not shown.

images/breads-1.avif

54.6 KB
Binary file not shown.

images/breads-10.avif

245 KB
Binary file not shown.

images/breads-2.avif

88.6 KB
Binary file not shown.

images/breads-3.avif

233 KB
Binary file not shown.

images/breads-4.avif

152 KB
Binary file not shown.

images/breads-5.avif

133 KB
Binary file not shown.

images/breads-6.avif

47.4 KB
Binary file not shown.

images/breads-7.avif

156 KB
Binary file not shown.

images/breads-8.avif

142 KB
Binary file not shown.

images/breads-9.avif

90.3 KB
Binary file not shown.

images/buildings-1.avif

49.1 KB
Binary file not shown.

images/buildings-10.avif

27 KB
Binary file not shown.

images/buildings-2.avif

64.4 KB
Binary file not shown.

images/buildings-3.avif

42.8 KB
Binary file not shown.

images/buildings-4.avif

64.4 KB
Binary file not shown.

images/buildings-5.avif

65.6 KB
Binary file not shown.

images/buildings-6.avif

92.9 KB
Binary file not shown.

images/buildings-7.avif

102 KB
Binary file not shown.

images/buildings-8.avif

87.3 KB
Binary file not shown.

images/buildings-9.avif

81.3 KB
Binary file not shown.

images/cats-1.avif

15.8 KB
Binary file not shown.

images/cats-10.avif

61.2 KB
Binary file not shown.

images/cats-2.avif

64.6 KB
Binary file not shown.

images/cats-3.avif

59.3 KB
Binary file not shown.

images/cats-4.avif

57.1 KB
Binary file not shown.

images/cats-5.avif

72.9 KB
Binary file not shown.

images/cats-6.avif

16.8 KB
Binary file not shown.

images/cats-7.avif

50.1 KB
Binary file not shown.

images/cats-8.avif

115 KB
Binary file not shown.

images/cats-9.avif

65.5 KB
Binary file not shown.

images/coffee-1.avif

71.5 KB
Binary file not shown.

images/coffee-10.avif

54.5 KB
Binary file not shown.

images/coffee-2.avif

56.1 KB
Binary file not shown.

images/coffee-3.avif

99.7 KB
Binary file not shown.

images/coffee-4.avif

31 KB
Binary file not shown.

images/coffee-5.avif

27.5 KB
Binary file not shown.

images/coffee-6.avif

68.5 KB
Binary file not shown.

images/coffee-7.avif

28.3 KB
Binary file not shown.

images/coffee-8.avif

22.6 KB
Binary file not shown.

images/coffee-9.avif

56.7 KB
Binary file not shown.

images/dogs-1.avif

109 KB
Binary file not shown.

images/dogs-10.avif

92.4 KB
Binary file not shown.

images/dogs-2.avif

30.8 KB
Binary file not shown.

images/dogs-3.avif

20.3 KB
Binary file not shown.

images/dogs-4.avif

25.1 KB
Binary file not shown.

images/dogs-5.avif

22.6 KB
Binary file not shown.

images/dogs-6.avif

25.6 KB
Binary file not shown.

images/dogs-7.avif

40.3 KB
Binary file not shown.

images/dogs-8.avif

51 KB
Binary file not shown.

images/dogs-9.avif

47.3 KB
Binary file not shown.

images/flowers-1.avif

113 KB
Binary file not shown.

images/flowers-10.avif

88.6 KB
Binary file not shown.

images/flowers-2.avif

53.6 KB
Binary file not shown.

images/flowers-3.avif

85.2 KB
Binary file not shown.

images/flowers-4.avif

36 KB
Binary file not shown.

images/flowers-5.avif

54.2 KB
Binary file not shown.

images/flowers-6.avif

103 KB
Binary file not shown.

images/flowers-7.avif

53.5 KB
Binary file not shown.

images/flowers-8.avif

57.9 KB
Binary file not shown.

images/flowers-9.avif

23.4 KB
Binary file not shown.

nest-cli.json

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"$schema": "https://json.schemastore.org/nest-cli",
3+
"collection": "@nestjs/schematics",
4+
"sourceRoot": "src",
5+
"compilerOptions": {
6+
"deleteOutDir": true
7+
}
8+
}

0 commit comments

Comments
 (0)