https://github.com/xcrypt0r/watchdog
๐ถ Dcinside image crawler that includes NSFW detection (Enhanced version of Hyacinth)
https://github.com/xcrypt0r/watchdog
crawler crawling dc dcinside nodejs nsfw parsing tensorflow
Last synced: 3 months ago
JSON representation
๐ถ Dcinside image crawler that includes NSFW detection (Enhanced version of Hyacinth)
- Host: GitHub
- URL: https://github.com/xcrypt0r/watchdog
- Owner: xCrypt0r
- License: gpl-3.0
- Created: 2025-05-19T17:56:34.000Z (5 months ago)
- Default Branch: main
- Last Pushed: 2025-05-25T13:54:46.000Z (4 months ago)
- Last Synced: 2025-06-20T18:43:36.420Z (4 months ago)
- Topics: crawler, crawling, dc, dcinside, nodejs, nsfw, parsing, tensorflow
- Language: TypeScript
- Homepage:
- Size: 13.9 MB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Watchdog
[][typescript]
[](LICENSE)
[](/../../)
[](https://github.com/xcrypt0r/Watchdog/actions/workflows/docker-build.yml)
[](https://hub.docker.com/r/xcrypt0r/watchdog)๐ถ **Watchdog** is a Dcinside image crawler that includes NSFW detection.
## ๋ชฉ์ฐจ
- [Watchdog](#watchdog)
- [๋ชฉ์ฐจ](#๋ชฉ์ฐจ)
- [์๊ฐ](#์๊ฐ)
- [์ค์น](#์ค์น)
- [๋น๋ ๊ฒฐ๊ณผ](#๋น๋-๊ฒฐ๊ณผ)
- [๊ณตํต](#๊ณตํต)
- [๋ก์ปฌ](#๋ก์ปฌ)
- [๋์ปค](#๋์ปค)
- [์ฌ์ฉ๋ฒ](#์ฌ์ฉ๋ฒ)
- [์ ์](#์ ์)
- [๋ผ์ด์ ์ค](#๋ผ์ด์ ์ค)## ์๊ฐ
**Watchdog**์ Node.js๋ฅผ ์ฌ์ฉํ์ฌ [๋์์ธ์ฌ์ด๋](https://www.dcinside.com)์์ ์ด๋ฏธ์ง๋ฅผ ํฌ๋กค๋งํ๊ณ
[TensorFlow](https://github.com/tensorflow/tfjs) ๊ธฐ๋ฐ NSFW ๋ชจ๋ธ์ ํตํด ์ด๋ฏธ์ง์ NSFW ์ฌ๋ถ๋ฅผ ํ๋จํ๊ณ ๋ถ๋ฅํ๋ ํ๋ก๊ทธ๋จ์ ๋๋ค.
## ์ค์น
### ๋น๋ ๊ฒฐ๊ณผ
|์ด์์ฒด์ |๊ฒฐ๊ณผ|
|---|:---:|
|Windows 11|โ ์ฑ๊ณต|
|Ubuntu 24.04|โ ์ฑ๊ณต|
|macOS Sequoia|โ ์ฑ๊ณต|
### ๊ณตํต
1. ์ด ๋ ํฌ์งํ ๋ฆฌ๋ฅผ [๋ค์ด๋ก๋](https://github.com/xCrypt0r/Watchdog/releases)ํฉ๋๋ค.
1. [Node.js][node.js]์ [npm][npm]์ ์ค์นํฉ๋๋ค.
- ํธํ๋๋ ๋ฒ์ ์ **20.x** ๋๋ **22.x**์ ๋๋ค.[^1]
- ๋ค๋ฅธ Node.js ๋ฒ์ ์ ์ฌ์ฉ ์ค์ผ ๊ฒฝ์ฐ [.nvmrc](.nvmrc) ํ์ผ์ ์ฐธ๊ณ ํด ๊ถ์ฅ ๋ฒ์ ์ ์ฌ์ฉํ ์ ์์ต๋๋ค.
[nvm](https://github.com/nvm-sh/nvm)์ ์ค์นํ๊ณ ๋ค์ ๋ช ๋ น์ด๋ก ๊ถ์ฅ ๋ฒ์ ์ ์ฌ์ฉํฉ๋๋ค.
```bash
nvm install 22
nvm use 22
node -v
```
2. `npm install`์ ์ ๋ ฅํ์ฌ ์์กด์ฑ์ ์ค์นํฉ๋๋ค.### ๋ก์ปฌ
1. [Python][python] **3.x** ๋ฒ์ ์ ์ค์นํฉ๋๋ค.
2. TensorFlow ๋น๋ ๋๊ตฌ๋ฅผ ์ค์นํฉ๋๋ค.
#### Windows
[Microsoft C++ Build Tools](https://visualstudio.microsoft.com/ko/visual-cpp-build-tools)๋ฅผ ์ค์นํฉ๋๋ค. ([๋งํฌ](https://rinkesh-patel.medium.com/easy-way-to-install-tensorflow-tfjs-node-in-windows-11-machine-158f049d9efa) ์ฐธ๊ณ )#### Linux
`sudo apt-get install build-essential`#### macOS
`xcode-select --install`
1. [.env.example](.env.example)์ `.env`๋ก, [targets.example.json](targets.example.json)์ `targets.json`์ผ๋ก ๋ณ๊ฒฝํฉ๋๋ค.
1. `npm start` ๋๋ `npm run pm2:start`๋ฅผ ์ ๋ ฅํ์ฌ ํ๋ก๊ทธ๋จ์ ์คํํฉ๋๋ค.### ๋์ปค
1. [Docker][docker]๋ฅผ ์ค์นํฉ๋๋ค.
1. **(์ต์ )** Docker Desktop์ ์ค์ ์์ ์ต๋ ๋ฉ๋ชจ๋ฆฌ ์ฌ์ฉ๋์ ์กฐ์ ํฉ๋๋ค.
- ์ด ํ๋ก๊ทธ๋จ์ [ecosystem.config.js](ecosystem.config.js#L10)์ ์ค์ ์ ๋ฐ๋ผ pm2 ์ฌ์ฉ ์ ์ต๋ 16GB๊น์ง ๋ฉ๋ชจ๋ฆฌ๋ฅผ ์ฌ์ฉํ ์ ์์ผ๋ฏ๋ก, Docker ๋ฉ๋ชจ๋ฆฌ ์ ํ์ ์ด ์ด์์ผ๋ก ์ค์ ํ๊ฑฐ๋ ecosystem.config.js๋ฅผ ์์ ํ์ธ์.[^2]
2. ์๋ ๋ ๊ฐ์ง ๋ฐฉ๋ฒ ์ค ํ๋๋ฅผ ์ ํํ์ธ์.
- **(๊ถ์ฅ)** Docker Hub์์ ์ด๋ฏธ์ง๋ฅผ ๋ด๋ ค๋ฐ์ ์ปจํ ์ด๋๋ฅผ ์คํํฉ๋๋ค.
1. `npm run docker:up`
- ๋ก์ปฌ์์ ์ด๋ฏธ์ง๋ฅผ ๋น๋ํ๊ณ ์คํํฉ๋๋ค.
1. [.env.example](.env.example)์ `.env`๋ก, [targets.example.json](targets.example.json)์ `targets.json`์ผ๋ก ๋ณ๊ฒฝํฉ๋๋ค.
2. `npm run docker:build`## ์ฌ์ฉ๋ฒ
- ๊ธฐ๋ณธ์ ์ผ๋ก ์ด๋ฏธ์ง๋ ๋ ํฌ์งํ ๋ฆฌ ํ์์ archive ํด๋ ๋ด์ ์ ์ฅ๋ฉ๋๋ค.
์ ์ฅ ์์น๋ [.env](.env.example)ํ์ผ์ **LOCAL_ARCHIVE_DIR** ๊ฐ์ ์์ ํ์ฌ ๋ณ๊ฒฝํ ์ ์์ต๋๋ค.
- [targets.json](targets.example.json)์ ์์ ํ์ฌ ํฌ๋กค๋ง ๋์ ๊ฐค๋ฌ๋ฆฌ๋ฅผ ๊ด๋ฆฌํ ์ ์์ต๋๋ค.[^3]
- ๋์ ๊ฐค๋ฌ๋ฆฌ๋ ๋ค์๊ณผ ๊ฐ์ ํ์์ผ๋ก ์ ๋ ฅํฉ๋๋ค.```json
"๊ฐค๋ฌ๋ฆฌ ์์ด๋": {
"name": "๊ฐค๋ฌ๋ฆฌ ์ด๋ฆ",
"type": "๊ฐค๋ฌ๋ฆฌ ํ์ "
}
```
- ๊ฐค๋ฌ๋ฆฌ ์์ด๋๋ ๊ฐค๋ฌ๋ฆฌ URL์์ id=๋ค์ ๋์ค๋ ๋ถ๋ถ์ ๋๋ค.
์๋ฅผ ๋ค์ด ๊ตญ๋ด์ผ๊ตฌ ๊ฐค๋ฌ๋ฆฌ URL `https://gall.dcinside.com/board/lists?id=baseball_new11`์์ ๊ฐค๋ฌ๋ฆฌ ์์ด๋๋ `baseball_new11`์ ๋๋ค.
- ๊ฐค๋ฌ๋ฆฌ ํ์ ์ ๋ฉ์ธ: `main`, ๋ง์ด๋: `minor`, ๋ฏธ๋: `mini`๋ก ์์ฑํฉ๋๋ค.## ์ ์
Watchdog ยฉ xCrypt0r
Authored and maintained by xCrypt0r> GitHub [**@xCrypt0r**][my github]
> Discord [**@xcrypt0r**][my discord]## ๋ผ์ด์ ์ค
์ด ํ๋ก์ ํธ๋ [**GNU ์ผ๋ฐ ๊ณต์ค ์ฌ์ฉ ํ๊ฐ์ ๋ฒ์ 3.0 (GPLv3)**](LICENSE) ๋ผ์ด์ ์ค๋ฅผ ๋ฐ๋ฆ ๋๋ค.[^1]: ์ด์ธ์ ๋ฒ์ ์ค์น ์ TensorFlow์ ์์กด์ฑ ๋ฌธ์ ๋ก ์ ๋๋ก ๋์ํ์ง ์์ต๋๋ค.
[^2]: Windows์์ `WSL 2`๊ธฐ๋ฐ Docker Desktop์ ์ฌ์ฉํ๋ ๊ฒฝ์ฐ `.wslconfig`๋ก ๋ฉ๋ชจ๋ฆฌ ์ ํ์ ์ค์ ํ์ธ์.
[^3]: ๋์ ๊ฐค๋ฌ๋ฆฌ๊ฐ ๋ง์์ง์๋ก ๋ฉ๋ชจ๋ฆฌ ์ฌ์ฉ๋์ด ๋์์ง๋๋ค.[typescript]: https://www.typescriptlang.org
[node.js]: https://nodejs.org/ko
[npm]: https://www.npmjs.com
[python]: https://www.python.org/downloads
[docker]: https://docs.docker.com/get-started/get-docker
[my github]: https://github.com/xCrypt0r
[my discord]: https://discord.com/users/282821913968115713