Skip to content

Instantly share code, notes, and snippets.

@geekdada
Last active November 4, 2019 02:33
Show Gist options
  • Save geekdada/f3de25c1de41f7f8ba408a5937e91273 to your computer and use it in GitHub Desktop.
Save geekdada/f3de25c1de41f7f8ba408a5937e91273 to your computer and use it in GitHub Desktop.
Deploy Surgio gateway to my own server
const gateway = require('surgio/build/gateway');
const http = require('http');
http.createServer(gateway.createHttpServer()).listen(9000, () => {
console.log('Your app is running at http://127.0.0.1:9000');
});
@geekdada
Copy link
Author

geekdada commented Nov 4, 2019

index.js 必须放在 Surgio 规则仓库内。

运行:

node index.js

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment