Skip to content

Commit 05361f9

Browse files
committed
1 parent d0787cd commit 05361f9

File tree

4 files changed

+2
-4
lines changed

4 files changed

+2
-4
lines changed

.env

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
JWT_SECRET='jwtPrivateKey'
22
JWT_LIFE_TIME=1d
33

4-
IMG_UPLOAD_FOLDER=imageUploads/
54
BODY_PARSER_JSON_LIMIT="1mb"
65

76
APP_PORT=4200

docker-compose.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ services:
88
# DATABASE_URL: postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/${POSTGRES_DB}
99
# JWT_SECRET: ${JWT_SECRET}
1010
# JWT_LIFE_TIME: ${JWT_LIFE_TIME}
11-
# IMG_UPLOAD_FOLDER: ${IMG_UPLOAD_FOLDER}
1211
# BODY_PARSER_JSON_LIMIT: ${BODY_PARSER_JSON_LIMIT}
1312
# APP_FRONTEND_URL: ${APP_FRONTEND_URL}
1413
# ports:

src/main.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ async function bootstrap() {
3434
}
3535

3636
// serve images
37-
app.use(express.static(join(process.cwd(), process.env.IMG_UPLOAD_FOLDER || 'imageUploads/')));
37+
app.use(express.static(join(process.cwd(), 'imageUploads/')));
3838

3939
await app.listen(process.env.APP_PORT || 3000);
4040
}

src/shared/static/static.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ export class StaticService {
3838
}
3939

4040
private getImagePath(imageName: string): string {
41-
const dir = this.configService.get('IMG_UPLOAD_FOLDER');
41+
const dir = this.configService.get('imageUploads/');
4242
this.ensureDirectoryExistence(dir);
4343
return path.resolve(dir, imageName);
4444
}

0 commit comments

Comments
 (0)