I am trying to write my first application with hyperledger.
I am running on Windows 10 pro 64-bit (10.0, Build 15063).
I have followed the prerequisites below and have installed all the appropriate dependencies from the guide: http://hyperledger-fabric.readthedocs.io/en/latest/prereqs.html.
I am able to use the out of the box scripts ./byfn.sh -m generate to set up my first network.
While trying to execute the script (./startFabric.sh), I get the error
# don't rewrite paths for Windows Git Bash users export MSYS_NO_PATHCONV=1
docker-compose -f docker-compose.yml down
Removing network net_basic
docker-compose -f docker-compose.yml up -d ca.example.com
orderer.example.com peer0.org1.example.com couchdb
Creating network "net_basic" with the default driver
Pulling couchdb (hyperledger/fabric-couchdb:latest)...
ERROR: manifest for hyperledger/fabric-couchdb:latest not found
So I got to https://hub.docker.com/r/hyperledger/fabric-couchdb/
and see that there is no latest tag for fabric-couchdb image
and I download successfully:
docker pull hyperledger/fabric-couchdb:ppc64le-1.0.2
Status: Downloaded
newer image for hyperledger/fabric-couchdb:ppc64le-1.0.2
but I am still receiving the same error
ERROR: manifest for hyperledger/fabric-couchdb:latest not found
even though I can see with docker images that I do have the fabric-couchdb image
REPOSITORY TAG IMAGE ID
CREATED SIZE
hyperledger/fabric-ca latest 7e53be14f804 3
weeks ago 238MB
hyperledger/fabric-ca x86_64-1.0.2 7e53be14f804 3
weeks ago 238MB
hyperledger/fabric-couchdb ppc64le-1.0.2 3a7f22fa9375 3
weeks ago 1.61GB
Is there a way I can get the startFabric.sh to execute properly without the latest couchdb tag?
I fixed the problem.
In "~/abric/fabric-samples/basic-network/docker-compose.yml", in the couchdb section, change the line:
image: hyperledger/fabric-couchdb
to
image: hyperledger/fabric-couchdb:x86_64-0.4.6
This is because Docker automatically pulls the latest image if no specific tag is provided.
I had the same issue a couple of days back on Ubuntu 16! Unfortunately, I missed a step "Download Platform-specific Binaries" in the setup process which didn't installed few required tools like Cryptogen.
Install the tools using the command curl -sSL https://raw.githubusercontent.com/hyperledger/fabric/v1.0.6/scripts/bootstrap.sh | bash -s 1.0.6
Set the path to the bin directory of the installation folder export PATH=<path to download location>/bin:$PATH
Hope it works for you
It seems that you've got a wong edition of hyperleddger/fabric-couchdb, the ppc641e-1.0.2 should go to x86_64-1.0.2. Once right, you can call docker tag to tag it be latest.
Related
Hi I need to modify the a docker image from Autoware_AI repository after build it. The problem is:
A) I build the image running a .sh file:
cd $WORKING_DIRECTORY/docker/generic
./run.sh -t 1.14.0
It is specifically from Autoware: https://www.svlsimulator.com/docs/system-under-test/autoware-instructions/
B) I modify the scripts contained inside the packages contained in Autoware folder
C) When I exit the container, and later enter again the modifications are not there anymore, of coure, because the image is built from Dockerfile from scratch...
To find a solution I have tried 2 different approachs:
To modify the container and save it as described here: https://www.scalyr.com/blog/create-docker-image/
Issue: When using other terminal, trying to add .txt file for Autoware_AI running container, to modify the container, Autoware_AI container does not appear as active (but it is). Just other container are avaialable when I try to copy a file to Autoware_AI:
Commit Changes To a Docker image: https://phoenixnap.com/kb/how-to-commit-changes-to-docker-image
Issue: Problem to connect to Autoware_AI server and run the ros packages. This problem does not happen when building the original Docker file with .sh
The complete description of my problem as well as output of terminal attempts are better described here:
https://answers.ros.org/question/376512/fork-autoware_ai-repository-and-create-docker-image/?answer=376583#post-id-376583
https://get-help.robotigniteacademy.com/t/fork-autoware-ai-repository-and-create-docker-image/9533/4
I am kind of new in forking,changing docker images. I do not understand how to fix this, find a solution for create my custom docker image and make it functional.
Thanks very much in advance!
As David Maze suggested one feasible way would be change the Dockerfile, and then build my image from it. It is a good idea. In my case however additional steps were required, because I had a build.sh script that called different Dockerfiles to build the image, and besides that this build.sh file also installed some ROS packages and other dependencies.
Even if the build.sh needed to change. The modifications on Dockerfile contributed to solve 90% of the issue. My Dockerfile was:
enter image description here
And After the modification, the Dockerfile became:
enter image description here
To dowload the modified ROS codes to my image, instead of autoware repo ROS pkgs, I needed:
1 - Copy the autoware.ai.repos file from here:
https://raw.githubusercontent.com/Autoware-AI/autoware.ai/1.14.0/autoware.ai.repos
To my docker local folder (docker/generic) and unwrap them with vcs import command as the Dockerfile displays above...
2- Edit the autoware.ai.repos, in order to change the address of some of the repositories contained in autoware.ai.repos to my personal github:
I Removed the lines:
autoware/visualization:
type: git
url: https://github.com/Autoware-AI/visualization.git
version: 1.14.0
And replaced by:
autoware/visualization:
type: git
url: https://github.com/marcusvinicius178/visualization
Afterwards I followed the build instructions in case 3 here: https://github.com/Autoware-AI/autoware.ai/wiki/Generic-x86-Docker#run-an-autoware-docker-container
$ ./build.sh
$ ./run.sh -t local
I know that may exist a more professional way to work with Docker images, and build a new Dockerfile based on the original one. But I am not that expert in Docker and also in this way my problem was solved.
I cannot mount a local folder to a docker volume on docker-compose
so it is not accessible on docker-compose run cmd.
Here is a repo from the github https://github.com/up1/demo-k6-docker
When I follow readme on docker-compose run k6 run scripts/sample.js it gives me the following error all the time:
WARN[0000] The moduleSpecifier "scripts/sample.js" has no scheme but we will try to resolve it as remote module. This will be deprecated in the future and all remote modules will need to explicitly use "https" as scheme. ERRO[0000] The moduleSpecifier "scripts/sample.js" couldn't be found on local disk. Make sure that you've specified the right path to the file. If you're running k6 using the Docker image make sure you have mounted the local directory (-v /local/path/:/inside/docker/path) containing your script and modules so that they're accessible by k6 from inside of the container, see https://k6.io/docs/using-k6/modules#using-local-modules-with-docker. Additionally it was tried to be loaded as remote module by prepending "https://" to it, which also didn't work. Remote resolution error: "Get "https://scripts/sample.js": dial tcp: lookup scripts on 127.0.0.11:53: no such host"
Tried:
specifically sharing folder in docker app settings window,
different github repos,
different mac laptops,
different setups Dockerfile copy and -v option on docker run
looking for similar questions
and docs
https://k6.io/docs/using-k6/modules#using-local-modules-with-docker
I would really appreciate some help, banging my head against the wall for a couple of days with this
Try this.
docker-compose run k6 run //scripts//sample.js
I'm running on docker desktop version 3.1.0 Windows 10 pro.
Solution
I wanted to install CVAT for training an Object Detection AI using Docker. The install failed for some reason in the middle and it wasn't installed. But all the files were still occupying space on my machine. I tried reinstalling the CVAT and the files keep adding to the occupied space. How do I remove all of these files? I am using a MacBook Pro with MacOS Big Sur Beta 4.
Edit: https://github.com/opencv/cvat/blob/develop/cvat/apps/documentation/installation.md#mac-os-mojave
These are the commands I am running to install CVAT.
docker-compose build output: https://pastebin.com/7EkeQ289
docker-compose up -d output: https://pastebin.com/hF3GFDkX
docker exec -it cvat bash -ic 'python3 ~/manage.py createsuperuser output: https://pastebin.com/Mfh8CivL
If you are trying to remove the containers, attempt the following:
1. docker ps -a - lists all containers
2. docker stop [label or SHA of the containers you want to remove]
docker-compose down [YAML configuration file you targeted with docker-compose up] - this should stop all containers, teardown networks, etc. that docker-compose started with 'up'
docker container prune - removes all stopped containers
NOTE: If you have other stopped containers that you want to keep, do not run this, but remove them individually, as I suggested in the stricken-through step two above, or Konrad Botor's comment
https://docs.docker.com/compose/reference/down/
https://docs.docker.com/engine/reference/commandline/container_prune/
If you want to remove the images:
docker images
docker rmi [label or SHA] (RMI is the remove image command)
https://docs.docker.com/engine/reference/commandline/images/
https://docs.docker.com/engine/reference/commandline/rmi/
To speed up this process, analyze the YAML configuration file being targeted for your docker-compose build command, and/or reference the documentation for that specific project (CVAT) if available, to determine what containers (software) it is initializing (and how it is doing so, if necessary). It might help to paste its contents in the question.
Note: what is taking up space may be volumes which are not cleaned up properly by the docker build scripts for this project. See the following documentation on how to remove those:
https://docs.docker.com/engine/reference/commandline/volume_rm/
I might be missing some context, as I cannot access your pastebin links (behind a firewall at the moment).
I am a beginner in docker and I am trying to run a Q&A website locally in my browser. I have found an open source container on the link https://hub.docker.com/r/zout84/askbot-docker. Here are the steps that I have done:
I have downloaded docker toolbox DockerToolbox-19.03.1.exe to be able to run docker using my Windows terminal.
Following the instructions on the above link I have run the command docker run -v /tmp/askbot:/data/ -p 8080:80 -d zout84/askbot-docker. Since I am on Windows I have replaced /tmp/askbot:/data/ by a folder I have created.
I have downloaded the container and put it a local folder that I called Docker_source. I have replaced zout84/askbot-docker by C:\Docker_source in the above docker run command
Now the error that I have is docker: invalid reference format: repository name must be lowercase.
Please, any suggestions on how to make it work?
Like the error said, The repository has to be lower case. It is called C:\Docker_source. You got a capital "D" over there. change it to a "d"
I am trying to generate my work in progress hugo website locally. It works fine with gitlab CI.
I installed docker and the gitlab runner service.
Then using the guide here I figured that I am supposed to do gitlab-runner exec docker pages.
But that results in:
[0;33mWARNING: Since GitLab Runner 10.0 this command is marked as DEPRECATED and will be removed in one of upcoming releases[0;m
[0KRunning with gitlab-runner 10.5.0 (80b03db9)
[0;m[0KUsing Docker executor with image rocker/tidyverse:latest ...
[0;m[0KPulling docker image rocker/tidyverse:latest ...
[0;m[0KUsing docker image sha256:f9a62417cb9b800a07695f86027801d8dfa34552c621738a80f5fed649c1bc80 for rocker/tidyverse:latest ...
[0;m[31;1mERROR: Job failed (system failure): Error response from daemon: invalid volume specification: '/host_mnt/c/builds/project-0/Users/jan/Desktop/gits/stanstrup-web:C:\Users\jan\Desktop\gits\stanstrup-web:ro'
[0;m[31;1mFATAL: Error response from daemon: invalid volume specification: '/host_mnt/c/builds/project-0/Users/jan/Desktop/gits/stanstrup-web:C:\Users\jan\Desktop\gits\stanstrup-web:ro'[0;m
I also tried registering it as other guides show but I end up with the same issue.
Others have had some issues:
https://gitlab.com/gitlab-org/gitlab-runner/issues/1775 It was said it was fixed...
https://github.com/moby/moby/issues/12751 suggest that you can set COMPOSE_CONVERT_WINDOWS_PATHS=1. I tried setting that as an environmental variable but it didn't help.
More discussion of how to escape the path correctly: https://github.com/docker/compose/issues/3285
More discussion sugestion COMPOSE_CONVERT_WINDOWS_PATHS=1 would work: https://github.com/docker/toolbox/issues/607
Am I supposed to set something in .gitlab-ci.yml? Should volumes be set there? In which case how/where?
The .gitlab-ci.yml says:
image: rocker/tidyverse:latest
before_script:
- apt-get update && apt-get -y install default-jdk pandoc r-base r-cran-rjava curl netcdf-bin libnetcdf-dev libxml2-dev libssl-dev
- R CMD javareconf
- Rscript .gitlab-ci.R
pages:
script:
- R -e "blogdown::build_site()"
artifacts:
paths:
- public
only:
- master
Looks like you hit the colon seperator bug in docker for windows which lots of tools have to work around , gitlab has noticed it
until the fix comes out the simplest workaround would be for you to try doing this in a linux vm on your windows box.
get prebuilt gitlab vm images from bitnami here.
otherwise you could checkout and run the gitlab-runner source branch with the fix, however it shows some conflicts and might have other bugs.