Merge pull request #101 from ryanxcharles/feature/improve-default-config
Improve default config + Add local express server + Update README
This commit is contained in:
commit
37e2cc8cb4
6 changed files with 49 additions and 7 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
|
@ -40,4 +40,4 @@ lib/*
|
||||||
!lib/socket.io.js
|
!lib/socket.io.js
|
||||||
|
|
||||||
js/copayBundle.js
|
js/copayBundle.js
|
||||||
js/config.js
|
config.js
|
||||||
|
|
|
||||||
28
README.md
28
README.md
|
|
@ -1 +1,29 @@
|
||||||
Copay
|
Copay
|
||||||
|
=====
|
||||||
|
|
||||||
|
Installation:
|
||||||
|
|
||||||
|
Copy config.template.js to config.js and edit to suit your needs. (Defaults to
|
||||||
|
public PeerJS and Insight servers)
|
||||||
|
|
||||||
|
Then execute these commands:
|
||||||
|
```
|
||||||
|
npm install
|
||||||
|
bower install
|
||||||
|
grunt --target=dev shell
|
||||||
|
node app.js
|
||||||
|
```
|
||||||
|
|
||||||
|
To run on a different port:
|
||||||
|
```
|
||||||
|
PORT=3001 node app.js
|
||||||
|
```
|
||||||
|
|
||||||
|
To open up five different instances to test 3-of-5 multisig with yourself, then run this in 5 different terminals:
|
||||||
|
```
|
||||||
|
PORT=3001 node app.js
|
||||||
|
PORT=3002 node app.js
|
||||||
|
PORT=3003 node app.js
|
||||||
|
PORT=3004 node app.js
|
||||||
|
PORT=3005 node app.js
|
||||||
|
```
|
||||||
|
|
|
||||||
12
app.js
Normal file
12
app.js
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
var express=require("express");
|
||||||
|
var http=require("http");
|
||||||
|
|
||||||
|
var app=express();
|
||||||
|
|
||||||
|
var port = process.env.PORT || 3000;
|
||||||
|
app.set("port", port);
|
||||||
|
app.use(express.static(__dirname));
|
||||||
|
|
||||||
|
app.listen(port, function(){
|
||||||
|
console.log("Listening at: http://localhost:" + port);
|
||||||
|
});
|
||||||
|
|
@ -3,12 +3,12 @@
|
||||||
var config = {
|
var config = {
|
||||||
networkName: 'testnet',
|
networkName: 'testnet',
|
||||||
network: {
|
network: {
|
||||||
// key: 'lwjd5qra8257b9',
|
key: 'lwjd5qra8257b9', //Copay API key for public PeerJS server
|
||||||
// This is for running local peerJs with params: ./peerjs -p 10009 -k 'sdfjhwefh'
|
// This is for running local peerJs with params: ./peerjs -p 10009 -k 'sdfjhwefh'
|
||||||
key: 'sdfjhwefh',
|
//key: 'sdfjhwefh',
|
||||||
host: 'localhost',
|
//host: 'localhost',
|
||||||
port: 10009,
|
//port: 10009,
|
||||||
path: '/',
|
//path: '/',
|
||||||
maxPeers: 3,
|
maxPeers: 3,
|
||||||
debug: 3,
|
debug: 3,
|
||||||
},
|
},
|
||||||
|
|
@ -392,6 +392,8 @@ missing
|
||||||
<p class="text-center"><a href="#/">go back...</a></p>
|
<p class="text-center"><a href="#/">go back...</a></p>
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
<script src="config.js"></script>
|
||||||
|
|
||||||
<script src="lib/angular/angular.min.js"></script>
|
<script src="lib/angular/angular.min.js"></script>
|
||||||
<script src="lib/qrcode-generator/js/qrcode.js"></script>
|
<script src="lib/qrcode-generator/js/qrcode.js"></script>
|
||||||
<script src="lib/angular-qrcode/qrcode.js"></script>
|
<script src="lib/angular-qrcode/qrcode.js"></script>
|
||||||
|
|
@ -406,7 +408,6 @@ missing
|
||||||
<script src="js/copayBundle.js"></script>
|
<script src="js/copayBundle.js"></script>
|
||||||
|
|
||||||
<script src="js/app.js"></script>
|
<script src="js/app.js"></script>
|
||||||
<script src="js/config.js"></script>
|
|
||||||
<script src="js/routes.js"></script>
|
<script src="js/routes.js"></script>
|
||||||
<script src="js/directives.js"></script>
|
<script src="js/directives.js"></script>
|
||||||
<script src="js/filters.js"></script>
|
<script src="js/filters.js"></script>
|
||||||
|
|
|
||||||
|
|
@ -19,6 +19,7 @@
|
||||||
},
|
},
|
||||||
"homepage": "https://github.com/bitpay/copay",
|
"homepage": "https://github.com/bitpay/copay",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"express": "4.0.0",
|
||||||
"grunt-contrib-watch": "~0.5.3",
|
"grunt-contrib-watch": "~0.5.3",
|
||||||
"grunt-mocha-test": "~0.8.2",
|
"grunt-mocha-test": "~0.8.2",
|
||||||
"grunt-shell": "~0.6.4",
|
"grunt-shell": "~0.6.4",
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue