https://github.com/toweringcloud/express-wetube-challenge
fullstack video community web app using express v4 + pug + ffmpeg + mongodb + minio
https://github.com/toweringcloud/express-wetube-challenge
cloudflare-r2 falai flyio github-oidc mongodb-atlas
Last synced: 4 months ago
JSON representation
fullstack video community web app using express v4 + pug + ffmpeg + mongodb + minio
- Host: GitHub
- URL: https://github.com/toweringcloud/express-wetube-challenge
- Owner: toweringcloud
- License: mit
- Created: 2025-07-07T13:02:29.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2025-07-16T05:53:48.000Z (6 months ago)
- Last Synced: 2025-07-16T06:57:20.205Z (6 months ago)
- Topics: cloudflare-r2, falai, flyio, github-oidc, mongodb-atlas
- Language: JavaScript
- Homepage: https://express-wetube-challenge.fly.dev
- Size: 171 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# express-wetube-challenge
fullstack video community web app using express v4 + pug + ffmpeg + mongodb + minio
## how to run
### setup
- install latest nodejs runtime
```sh
$ node -v
v22.16.0
$ npm -v
10.9.2
```
### configure
- install packages with npm packager
```sh
$ npm init
$ npm i
```
- create runtime variables
```sh
$ cat .env
MODE=DEV
API_SERVER_URL=http://localhost
API_PORT_NO=3000
COOKIE_SECRET={YOUR_COOKIE_SECRET}
GITHUB_API_URL=https://api.github.com
GITHUB_AUTH_URL=https://github.com/login/oauth
GITHUB_CALLBACK_URL=http://localhost:3000/github/callback
GITHUB_CLIENT_ID={YOUR_GITHUB_CLIENT_ID}
GITHUB_CLIENT_SECRET={YOUR_GITHUB_CLIENT_SECRET}
DATABASE_URL=mongodb://id:pw@127.0.0.1:27017/wetube
STORAGE_SERVER="minio | cloudflare r2 | aws s3"
STORAGE_REGION=auto
STORAGE_ENDPOINT_URL={YOUR_ENDPOINT_URL}
STORAGE_ACCESS_KEY_ID={YOUR_ACCESS_KEY_ID}
STORAGE_SECRET_ACCESS_KEY={YOUR_SECRET_ACCESS_KEY}
STORAGE_DOWNLOAD_URL_VIDEO={YOUR_PUBLIC_VIDEO_DOMAIN}
STORAGE_DOWNLOAD_URL_IMAGE={YOUR_PUBLIC_IMAGE_DOMAIN}
```
### launch
- run nodejs apps with development mode
```sh
$ npm run dev:assets
asset js/main.js 3.41 KiB [compared for emit] (name: main)
asset css/styles.css 881 bytes [compared for emit] (name: main)
...
webpack 5.99.9 compiled successfully in 823 ms
$ npm run dev:server
...
[nodemon] starting `babel-node src/index.js`
✅ Server listenting on http://localhost:4567 🚀
✅ Connected to DB
```
- deploy nodejs apps with production mode
```sh
$ curl -L https://fly.io/install.sh | sh
$ fly launch
$ fly deploy
```
### test
- download sample video file
- [Pexcel](https://www.pexels.com)
- [Others](https://www.sample-videos.com)