Signed-off-by: Matthias Sieber <matthias.sieber@loxeinc.com>
This commit is contained in:
Matthias Sieber 2022-10-30 21:28:49 -07:00
parent a0e767d838
commit 2c9f8fbc20
8 changed files with 15 additions and 16 deletions

View file

@ -3,8 +3,8 @@
*/
import { Gateway, Wallets } from 'fabric-network';
import * as path from 'path';
import * as fs from 'fs';
import * as path from 'path';
async function main() {
try {

View file

@ -3,9 +3,8 @@
*/
import { Gateway, Wallets } from 'fabric-network';
import * as path from 'path';
import * as fs from 'fs';
import * as path from 'path';
async function main() {
try {

View file

@ -2,16 +2,16 @@
* SPDX-License-Identifier: Apache-2.0
*/
import { Wallets, X509Identity } from 'fabric-network';
import * as FabricCAServices from 'fabric-ca-client';
import * as path from 'path';
import { Wallets, X509Identity } from 'fabric-network';
import * as fs from 'fs';
import * as path from 'path';
async function main() {
try {
// load the network configuration
const ccpPath = path.resolve(__dirname, '..', '..', '..', 'test-network', 'organizations', 'peerOrganizations', 'org1.example.com', 'connection-org1.json');
let ccp = JSON.parse(fs.readFileSync(ccpPath, 'utf8'));
const ccp = JSON.parse(fs.readFileSync(ccpPath, 'utf8'));
// Create a new CA client for interacting with the CA.
const caURL = ccp.certificateAuthorities['ca.org1.example.com'].url;