Incorrect command error for composer network deploy - hyperledger-composer

I'm following this tutorial on macOS.
$ composer -v
v0.20.1
$ composer network deploy -a dist/iot-perishable-network.bna -A admin -S adminpw -c PeerAdmin#hlfv1 -f networkadmin.card
Incorrect command. Please see the list of commands above, or enter "composer network --help".
Available composer network commands in the list mentioned above: download, install, list, loglevel, ping, reset, start, upgrade

You are using Composer v0.20.1, the tutorial you are referring to is using Composer v0.15.0.
The deploy command has been removed since Hyperledger 0.19.0.
See https://github.com/hyperledger/composer/releases/tag/v0.19.0 :
The following commands are no longer valid:
composer runtime install
composer network deploy
composer network update
composer network undeploy
You now have to use the following commands instead :
composer network install
composer network start
composer network upgrade
See https://hyperledger.github.io/composer/latest/reference/commands for last valid commands.

Related

Drupal 8 run composer as root

My host provider allows me to use only root user (the only one with /bin/bash) on my virtual machine that I'm using to host a drupal 8 site installed with composer.
From composer website I see they strongly advise to avoid running composer as super-user/root, they say to use composer install --no-plugins
I tried the command apt-get composer install --no-plugins but outputs the error
E: Command line option --no-plugins is not understood in combination
with the other option
I'm still running composer as root, even thought there is always an alert, how can avoid that?
If Composer is already installed, there is no need to call apt-get, which is the standard package installer on Debian systems. composer install --no-plugins does the job

composer network deploy, command not found

I am doing this tutorial: https://www.ibm.com/developerworks/cloud/library/cl-deploy-interact-extend-local-blockchain-network-with-hyperledger-composer/index.html
And here I have to do composer network deploy but this is what I get:
composer network <subcommand>
Composer network command
Commands:
composer network download [options] Downloads a business network from the Hyperledger Fabric, does not undeploy
composer network install [options] Installs a business network archive to Hyperledger Fabric
composer network list [options] List the contents of a business network
composer network loglevel [options] Change the logging level of a business network
composer network ping [options] Test a connection to a business network
composer network reset [options] Resets a business network
composer network start [options] Starts a specific version of a business network that is already installed to Hyperledger Fabric
composer network upgrade [options] Upgrades to a specific version of a business network that is already installed to Hyperledger Fabric
Options:
--help Show help [boolean]
-v, --version Show version number [boolean]
Incorrect command. Please see the list of commands above, or enter "composer network --help".
So my Question here is if this command got changed to composer network install?
Yes the command has been changed to composer network install. You can follow documentation of composer for the commands.

Composer install log location on Ubuntu

I am trying to install Drupal's OpenEdu project on Ubuntu 16.04 with composer by running the following command:
composer create-project imagex/openedu-project openedu
This produces a load of messages pertaining to PHP settings, and the project is not installed. The problem is that I cannot see all the messages on the screen (VMware console), only the last x lines.
The question is: where can I see the full result of the attempt at creation of the project?
You can redirect composer output to file:
composer create-project imagex/openedu-project openedu --no-interaction --no-progress > install.log 2>&1
And then use less to browse the file:
less install.log

command line composer command not defined

I am following the composer developer Tutorial: https://hyperledger.github.io/composer/tutorials/developer-guide.html
Everything worked till the point when I am running from the command line:
$ composer archive create -a dist/my-network.bna --sourceType dir --sourceName .
-bash: fds: command not found
The composer command was not found. When built by npm install the script can execute the composer command within the package.json
Next I installed php composer from: https://getcomposer.org - Which might be the wrong package?
$ composer network deploy
[Symfony\Component\Console\Exception\CommandNotFoundException]
Command "network" is not defined.
My 2 questions: is this the right package, if not how can I remove it safely?
Furthermore, how can I execute the composer command.
You need to npm install -g composer-cli -- please refer to the documentation.

Could not deploy business network to hyperledger fabric beta using composer

I have tried to deploy a business network using composer to but it fails with the following error
Error: event message must be properly signed by an identity from the same organization as the peer: [Expected MSP ID Org1MSP, received ]]
what is the problem ?
There are several reasons why you might get this error
You are not running composer v0.8.0 or higher. You can check what level you are running by invoking the command
composer -v
You haven't specified a valid hlfv1 profile or you forgot to specify the profile to use on the network deploy command. If you have followed the tutorials and guides on the hyperledger composer site then a profile will have been created called hlfv1. Ensure you specify it on the command line invocations. For example to deploy
composer network deploy -a test.bna -i PeerAdmin -s anything -p hlfv1
You are running an older version of docker. Level may be checked by invoking the command: docker -v
Invoking the ./prereqs-ubuntu.sh detailed in the 'Installing a developing with Hyperledger Composer' will update the prerequisites accordingly.

Resources