Skip to content

HuijiFE/media-embed

Repository files navigation

Media Embed

Covert web page url of media to <iframe> tag and get info of media.

Usage

Dependencies

npm run frame

Depending on the package lock file ("package-lock.json" or "yarn.lock"), you might need to install yarn.

Development

$ npm run dev

DevOps

  • Build the project.
npm run tsc
  • Start the server.
npm start
  • Stop the server.
npm run stop

The project included the process manager "pm2", you DO NOT need to install "pm2" or "forever" globally.

Configuration

Environment variables

To configure the port number and other environment variables, create a file ".env" and edit it just like ".env.example". The file ".env" is ignore by git, so that it can store some secret info.

NODE_ENV=production
PORT=7100
SOME_API_KEY=xxxxxxxx

Or use command line (before starting server):

printf "NODE_ENV=production\nPORT=7100\nSOME_API_KEY=xxxxxxxx" > .env

CORS

Look at the expressjs/cors.

About

An embed library for video and audio.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published