1.0.0 • Published 3 years ago
coveringcdn v1.0.0
CDNCovering
When CDN is down, CDNCovering can detect it, and run designated commands automatically.
Install
$ npm i CDNCovering
const CDNCovering = require("CDNCovering")
how to use
CDNCovering has two modes: localfile (ex. ./public/index.html) and remotefile (ex. https://www.rintaro.tech)
1. Localfile mode
CDNCovering.local(path, command)
Path means the path of the file that you want to check CDN status.\ Command means the command that you want to run when CDN is down.\ Example:
CDNCovering.local('./public/index.html', 'heroku logs')
2. Remotefile mode
CDNCovering.remote(uri, command)
Example:
CDNCovering.remote('https://www.rintaro.tech', 'heorku logs')
LICENSE
This software is released under the MIT license.
1.0.0
3 years ago