Skip to content

Commit

Permalink
chore: add error notification when having exception
Browse files Browse the repository at this point in the history
  • Loading branch information
MinhhTien committed May 5, 2024
1 parent 08e0699 commit 2588705
Show file tree
Hide file tree
Showing 9 changed files with 320 additions and 12 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/develop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,9 @@ jobs:
echo SENTRY_DSN=${{ secrets.SENTRY_DSN }} >> .env
echo DISCORD_WEBHOOK_ID=${{ secrets.DISCORD_WEBHOOK_ID }} >> .env
echo DISCORD_WEBHOOK_TOKEN=${{ secrets.DISCORD_WEBHOOK_TOKEN }} >> .env
- name: Deploy
run: pm2 restart furnique-api

Expand Down
4 changes: 4 additions & 0 deletions example.env
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ CORS_VALID_ORIGINS=localhost,ngrok-free
WEB_URL=https://www.furnique.tech
SERVER_URL=https://api.furnique.tech

#Discord webhook
DISCORD_WEBHOOK_ID=
DISCORD_WEBHOOK_TOKEN=

## PAYMENT
#MOMO
MOMO_PARTNER_CODE=
Expand Down
243 changes: 241 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
"bcrypt": "^5.1.1",
"class-transformer": "^0.5.1",
"class-validator": "^0.14.1",
"discord.js": "^14.15.1",
"ejs": "^3.1.9",
"google-auth-library": "^9.5.0",
"lodash": "^4.17.21",
Expand Down Expand Up @@ -103,4 +104,4 @@
"coverageDirectory": "../coverage",
"testEnvironment": "node"
}
}
}
5 changes: 3 additions & 2 deletions src/common/common.module.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import { Global, Module } from '@nestjs/common'
import { AppLogger } from '@common/services/app-logger.service'
import { HelperService } from '@common/services/helper.service'
import { DiscordService } from './services/discord.service'

@Global()
@Module({
providers: [AppLogger, HelperService],
exports: [AppLogger, HelperService]
providers: [AppLogger, HelperService, DiscordService],
exports: [AppLogger, HelperService, DiscordService]
})
export class CommonModule {}
Loading

0 comments on commit 2588705

Please sign in to comment.