mirror of
https://github.com/hyperledger/fabric-samples.git
synced 2026-06-25 19:15:10 +00:00
Udpdated Admin/User
This commit is contained in:
parent
ef5e91f82b
commit
324e03b56a
4 changed files with 5 additions and 3 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -16,6 +16,7 @@ vendor/
|
||||||
.idea
|
.idea
|
||||||
# Dependency directories
|
# Dependency directories
|
||||||
node_modules/
|
node_modules/
|
||||||
|
wallet/
|
||||||
# Ignore Gradle build output directory
|
# Ignore Gradle build output directory
|
||||||
build
|
build
|
||||||
package-lock.json
|
package-lock.json
|
||||||
|
|
|
||||||
|
|
@ -37,7 +37,7 @@ Fabric_Client.newDefaultKeyValueStore({ path: store_path
|
||||||
verify: false
|
verify: false
|
||||||
};
|
};
|
||||||
// be sure to change the http to https when the CA is running TLS enabled
|
// be sure to change the http to https when the CA is running TLS enabled
|
||||||
fabric_ca_client = new Fabric_CA_Client('http://localhost:7054', tlsOptions , 'ca.example.com', crypto_suite);
|
fabric_ca_client = new Fabric_CA_Client('https://localhost:7054', tlsOptions , 'ca.example.com', crypto_suite);
|
||||||
|
|
||||||
// first check to see if the admin is already enrolled
|
// first check to see if the admin is already enrolled
|
||||||
return fabric_client.getUserContext('admin', true);
|
return fabric_client.getUserContext('admin', true);
|
||||||
|
|
|
||||||
|
|
@ -41,7 +41,7 @@ Fabric_Client.newDefaultKeyValueStore({ path: store_path
|
||||||
verify: false
|
verify: false
|
||||||
};
|
};
|
||||||
// be sure to change the http to https when the CA is running TLS enabled
|
// be sure to change the http to https when the CA is running TLS enabled
|
||||||
fabric_ca_client = new Fabric_CA_Client('http://localhost:7054', null , '', crypto_suite);
|
fabric_ca_client = new Fabric_CA_Client('https://localhost:7054', null , '', crypto_suite);
|
||||||
|
|
||||||
// first check to see if the admin is already enrolled
|
// first check to see if the admin is already enrolled
|
||||||
return fabric_client.getUserContext('admin', true);
|
return fabric_client.getUserContext('admin', true);
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"description": "Hyperledger Fabric POC",
|
"description": "Hyperledger Fabric POC",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "nodemon -L server.js"
|
"start": "node server.js"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"angular": "^1.7.8",
|
"angular": "^1.7.8",
|
||||||
|
|
@ -12,6 +12,7 @@
|
||||||
"express": "latest",
|
"express": "latest",
|
||||||
"fabric-ca-client": "^2.2.4",
|
"fabric-ca-client": "^2.2.4",
|
||||||
"fabric-network": "^2.2.4"
|
"fabric-network": "^2.2.4"
|
||||||
|
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"nodemon": "^2.0.15"
|
"nodemon": "^2.0.15"
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue