This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Adaptation of the koa-mount boilerplate example expanded to include wildcards. | |
* Unfortunately, there are a number of bugs with wildcard matching and koa-router. | |
* Below is a workaround which consists of using regular expressions to "match all except" | |
* instead of a plain wildcard. | |
* | |
* Use at your own risk. | |
* --Matt Warner, July 2018 | |
* | |
* Original note: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
// Matt Warner, July 2018 | |
// Use at your own risk, no warranties, no guarantees, etc. | |
// Code to copy local files into the format used by serverless-s3-local (which uses S3rver) | |
const {promisify} = require('util'); | |
const fs = require('fs'); | |
const readFileAsync = promisify(fs.readFile); | |
const readDirAsync = promisify(fs.readdir); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
const net = require('net'); | |
const crypto = require('crypto'); | |
const tacacs = require('tacacs-plus'); | |
const AuthResult = Object.freeze({ | |
Success: 'Success', | |
Failure: 'Failure' | |
}); |