Can't start the local fabric in VSC environment when trying to deploy smart contract - docker

When using the IBM Blockchain Extension for VS Code; I wrote a sample smart contract and packaged it. But when I try to start the local fabric environment, I get an error saying:
Failed to start Local Fabric: Failed to execute command "cmd" with arguments "/c, start.cmd" return code 1
I was following the IBM tutorials for blockchain and installed all required software tools for the extension as listed by IBM in the following link:
N/A
This is part of the error:
[9/2/2019 8:09:46 PM] [INFO] C:\Users\sufij\.fabric-vscode\environments\local_fabric>echo Hyperledger Fabric started in seconds.
[9/2/2019 8:09:46 PM] [INFO] Hyperledger Fabric started in seconds
[9/2/2019 8:09:46 PM] [INFO] C:\Users\sufij\.fabric-vscode\environments\local_fabric>rem Check to see if the channel already exists
[9/2/2019 8:09:46 PM] [INFO] C:\Users\sufij\.fabric-vscode\environments\local_fabric>docker exec -e "CORE_PEER_LOCALMSPID=Org1MSP" -e "CORE_PEER_MSPCONFIGPATH=/etc/hyperledger/msp/users/Admin#org1.example.com/msp" fabricvscodelocalfabric_peer0.org1.example.com peer channel getinfo -c mychannel
[9/2/2019 8:09:46 PM] [INFO] Error: No such container: fabricvscodelocalfabric_peer0.org1.example.com
[9/2/2019 8:09:46 PM] [INFO] C:\Users\sufij\.fabric-vscode\environments\local_fabric>if errorlevel 1
[9/2/2019 8:09:46 PM] [INFO] (
[9/2/2019 8:09:46 PM] [INFO] rem Create the channel
[9/2/2019 8:09:46 PM] [INFO] docker exec -e "CORE_PEER_LOCALMSPID=Org1MSP" -e "CORE_PEER_MSPCONFIGPATH=/etc/hyperledger/msp/users/Admin#org1.example.com/msp" fabricvscodelocalfabric_peer0.org1.example.com peer channel create -o orderer.example.com:17050 -c mychannel -f /etc/hyperledger/configtx/channel.tx
[9/2/2019 8:09:46 PM] [INFO] rem Update the channel with the anchor peers
[9/2/2019 8:09:46 PM] [INFO] docker exec -e "CORE_PEER_LOCALMSPID=Org1MSP" -e "CORE_PEER_MSPCONFIGPATH=/etc/hyperledger/msp/users/Admin#org1.example.com/msp" fabricvscodelocalfabric_peer0.org1.example.com peer channel update -o orderer.example.com:17050 -c mychannel -f /etc/hyperledger/configtx/Org1MSPanchors.tx
[9/2/2019 8:09:46 PM] [INFO] rem Join peer0.org1.example.com to the channel.
[9/2/2019 8:09:46 PM] [INFO] docker exec -e "CORE_PEER_LOCALMSPID=Org1MSP" -e "CORE_PEER_MSPCONFIGPATH=/etc/hyperledger/msp/users/Admin#org1.example.com/msp" fabricvscodelocalfabric_peer0.org1.example.com peer channel join -b mychannel.block
[9/2/2019 8:09:46 PM] [INFO] )
[9/2/2019 8:09:46 PM] [INFO] Error: No such container: fabricvscodelocalfabric_peer0.org1.example.com
[9/2/2019 8:09:46 PM] [INFO] Error: No such container: fabricvscodelocalfabric_peer0.org1.example.com
[9/2/2019 8:09:46 PM] [INFO] Error: No such container: fabricvscodelocalfabric_peer0.org1.example.com
[9/2/2019 8:09:46 PM] [ERROR] Failed to start Local Fabric: Error: Failed to execute command "cmd" with arguments "/c, start.cmd" return code 1

Related

Infinite Loop when deploying to Elastic Beanstalk

I would like to deploy a Docker image containing Keycloak to Elastic Beanstalk.
To do so I created a Dockerfile like this.
FROM bitnami/keycloak:19.0.2
EXPOSE 5000
This deploys successfully when running eb deploy.
I would now like to compile some Java code and copy it into the Keycloak image.
FROM gradle:7.5.0-jdk11-alpine AS spi
COPY --chown=gradle:gradle ./spi /spi
WORKDIR /spi
RUN gradle build --no-daemon
FROM bitnami/keycloak:19
COPY --from=spi /spi/build/libs/* /opt/keycloak/providers/keycloak-spi-0.0.1-SNAPSHOT.jar
EXPOSE 5000
This builds successfully using docker build --no-cache -t keycloak . and can be run using docker run locally.
If I try deploying this to Elastic Beanstalk it deploys indefinitely. I can't cancel the deployment and have to force it to stop by setting the Auto Scaling Group capacity to 0.
----------------------------------------
/var/log/eb-hooks.log
----------------------------------------
----------------------------------------
/var/log/nginx/access.log
----------------------------------------
172.31.15.133 - - [29/Sep/2022:17:05:19 +0000] "GET / HTTP/1.1" 502 157 "-" "ELB-HealthChecker/2.0" "-"
172.31.35.107 - - [29/Sep/2022:17:05:19 +0000] "GET / HTTP/1.1" 502 157 "-" "ELB-HealthChecker/2.0" "-"
172.31.15.133 - - [29/Sep/2022:17:05:32 +0000] "GET / HTTP/1.1" 502 559 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36" "86.11.104.152"
172.31.15.133 - - [29/Sep/2022:17:05:34 +0000] "GET / HTTP/1.1" 502 157 "-" "ELB-HealthChecker/2.0" "-"
172.31.35.107 - - [29/Sep/2022:17:05:34 +0000] "GET / HTTP/1.1" 502 157 "-" "ELB-HealthChecker/2.0" "-"
----------------------------------------
/var/log/nginx/error.log
----------------------------------------
2022/09/29 17:05:19 [error] 4202#4202: *1 connect() failed (111: Connection refused) while connecting to upstream, client: 172.31.15.133, server: , request: "GET / HTTP/1.1", upstream: "http://172.17.0.2:5000/", host: "172.31.7.44"
2022/09/29 17:05:19 [error] 4202#4202: *3 connect() failed (111: Connection refused) while connecting to upstream, client: 172.31.35.107, server: , request: "GET / HTTP/1.1", upstream: "http://172.17.0.2:5000/", host: "172.31.7.44"
2022/09/29 17:05:32 [error] 4202#4202: *5 connect() failed (111: Connection refused) while connecting to upstream, client: 172.31.15.133, server: , request: "GET / HTTP/1.1", upstream: "http://172.17.0.2:5000/", host: "keycloak-dev.eu-west-2.elasticbeanstalk.com"
2022/09/29 17:05:34 [error] 4202#4202: *7 connect() failed (111: Connection refused) while connecting to upstream, client: 172.31.15.133, server: , request: "GET / HTTP/1.1", upstream: "http://172.17.0.2:5000/", host: "172.31.7.44"
2022/09/29 17:05:34 [error] 4202#4202: *9 connect() failed (111: Connection refused) while connecting to upstream, client: 172.31.35.107, server: , request: "GET / HTTP/1.1", upstream: "http://172.17.0.2:5000/", host: "172.31.7.44"
----------------------------------------
/var/log/eb-docker/containers/eb-current-app/eb-48320d59a48b-stdouterr.log
----------------------------------------
[38;5;6mkeycloak [38;5;5m17:05:06.31 [0m
[38;5;6mkeycloak [38;5;5m17:05:06.32 [0m[1mWelcome to the Bitnami keycloak container[0m
[38;5;6mkeycloak [38;5;5m17:05:06.32 [0mSubscribe to project updates by watching [1mhttps://github.com/bitnami/containers[0m
[38;5;6mkeycloak [38;5;5m17:05:06.32 [0mSubmit issues and feature requests at [1mhttps://github.com/bitnami/containers/issues[0m
[38;5;6mkeycloak [38;5;5m17:05:06.32 [0m
[38;5;6mkeycloak [38;5;5m17:05:06.32 [0m[38;5;2mINFO [0m ==> ** Starting keycloak setup **
[38;5;6mkeycloak [38;5;5m17:05:06.33 [0m[38;5;2mINFO [0m ==> Validating settings in KEYCLOAK_* env vars...
[38;5;6mkeycloak [38;5;5m17:05:06.35 [0m[38;5;2mINFO [0m ==> Trying to connect to PostgreSQL server awseb-e-2mwnvjecwe-stack-awsebrdsdatabase-qb51rlaqbaxv.czdgrvr4inhi.eu-west-2.rds.amazonaws.com...
[38;5;6mkeycloak [38;5;5m17:05:06.38 [0m[38;5;2mINFO [0m ==> Found PostgreSQL server listening at awseb-e-2mwnvjecwe-stack-awsebrdsdatabase-qb51rlaqbaxv.czdgrvr4inhi.eu-west-2.rds.amazonaws.com:5432
[38;5;6mkeycloak [38;5;5m17:05:06.38 [0m[38;5;2mINFO [0m ==> Configuring database settings
[38;5;6mkeycloak [38;5;5m17:05:06.41 [0m[38;5;2mINFO [0m ==> Enabling statistics
[38;5;6mkeycloak [38;5;5m17:05:06.41 [0m[38;5;2mINFO [0m ==> Configuring http settings
[38;5;6mkeycloak [38;5;5m17:05:06.42 [0m[38;5;2mINFO [0m ==> Configuring hostname settings
[38;5;6mkeycloak [38;5;5m17:05:06.43 [0m[38;5;2mINFO [0m ==> Configuring cache count
[38;5;6mkeycloak [38;5;5m17:05:06.43 [0m[38;5;2mINFO [0m ==> Configuring log level
[38;5;6mkeycloak [38;5;5m17:05:06.44 [0m[38;5;2mINFO [0m ==> Configuring proxy
[38;5;6mkeycloak [38;5;5m17:05:06.45 [0m[38;5;2mINFO [0m ==> ** keycloak setup finished! **
[38;5;6mkeycloak [38;5;5m17:05:06.46 [0m[38;5;2mINFO [0m ==> ** Starting keycloak **
Updating the configuration and installing your custom providers, if any. Please wait.
2022-09-29 17:05:19,703 WARN [org.keycloak.services] (build-43) KC-SERVICES0047: metrics (org.jboss.aerogear.keycloak.metrics.MetricsEndpointFactory) is implementing the internal SPI realm-restapi-extension. This SPI is internal and may change without notice
2022-09-29 17:05:21,233 WARN [org.keycloak.services] (build-43) KC-SERVICES0047: metrics-listener (org.jboss.aerogear.keycloak.metrics.MetricsEventListenerFactory) is implementing the internal SPI eventsListener. This SPI is internal and may change without notice
2022-09-29 17:05:32,212 INFO [io.quarkus.deployment.QuarkusAugmentor] (main) Quarkus augmentation completed in 21445ms
2022-09-29 17:05:35,762 INFO [org.keycloak.quarkus.runtime.hostname.DefaultHostnameProvider] (main) Hostname settings: Base URL: <unset>, Hostname: <request>, Strict HTTPS: false, Path: <request>, Strict BackChannel: false, Admin URL: <unset>, Admin: <request>, Port: -1, Proxied: true
2022-09-29 17:05:38,486 INFO [org.keycloak.common.crypto.CryptoIntegration] (main) Detected crypto provider: org.keycloak.crypto.def.DefaultCryptoProvider
----------------------------------------
/var/log/docker-events.log
----------------------------------------
2022-09-29T17:05:03.177179628Z image pull bitnami/keycloak:19 (name=bitnami/keycloak, org.opencontainers.image.authors=https://bitnami.com/contact, org.opencontainers.image.description=Application packaged by Bitnami, org.opencontainers.image.ref.name=19.0.2-debian-11-r4, org.opencontainers.image.source=https://github.com/bitnami/containers/tree/main/bitnami/keycloak, org.opencontainers.image.title=keycloak, org.opencontainers.image.vendor=VMware, Inc., org.opencontainers.image.version=19.0.2)
2022-09-29T17:05:03.398516443Z container create edf1b48a9117e98a17c3c65139a2c3131ba40c31cc036faba9d7e541eb1308a4 (image=sha256:2a52f7074b400c46837253be0cd6719054373aa15c556a2505cfc4875c732191, name=crazy_keldysh, org.opencontainers.image.authors=https://bitnami.com/contact, org.opencontainers.image.description=Application packaged by Bitnami, org.opencontainers.image.ref.name=19.0.2-debian-11-r4, org.opencontainers.image.source=https://github.com/bitnami/containers/tree/main/bitnami/keycloak, org.opencontainers.image.title=keycloak, org.opencontainers.image.vendor=VMware, Inc., org.opencontainers.image.version=19.0.2)
2022-09-29T17:05:03.467499766Z container destroy edf1b48a9117e98a17c3c65139a2c3131ba40c31cc036faba9d7e541eb1308a4 (image=sha256:2a52f7074b400c46837253be0cd6719054373aa15c556a2505cfc4875c732191, name=crazy_keldysh, org.opencontainers.image.authors=https://bitnami.com/contact, org.opencontainers.image.description=Application packaged by Bitnami, org.opencontainers.image.ref.name=19.0.2-debian-11-r4, org.opencontainers.image.source=https://github.com/bitnami/containers/tree/main/bitnami/keycloak, org.opencontainers.image.title=keycloak, org.opencontainers.image.vendor=VMware, Inc., org.opencontainers.image.version=19.0.2)
2022-09-29T17:05:03.471362994Z image tag sha256:5d99cf30b3aec76495a2db5b6e5292125f31f29ddfe7aca21789abd2f13fc30c (name=aws_beanstalk/staging-app:latest, org.opencontainers.image.authors=https://bitnami.com/contact, org.opencontainers.image.description=Application packaged by Bitnami, org.opencontainers.image.ref.name=19.0.2-debian-11-r4, org.opencontainers.image.source=https://github.com/bitnami/containers/tree/main/bitnami/keycloak, org.opencontainers.image.title=keycloak, org.opencontainers.image.vendor=VMware, Inc., org.opencontainers.image.version=19.0.2)
2022-09-29T17:05:05.646632020Z container create 48320d59a48b027ab5d08531271a2cd0c4cafac5e80f322fa7fc98c0849ba5b4 (image=5d99cf30b3ae, name=cool_pasteur, org.opencontainers.image.authors=https://bitnami.com/contact, org.opencontainers.image.description=Application packaged by Bitnami, org.opencontainers.image.ref.name=19.0.2-debian-11-r4, org.opencontainers.image.source=https://github.com/bitnami/containers/tree/main/bitnami/keycloak, org.opencontainers.image.title=keycloak, org.opencontainers.image.vendor=VMware, Inc., org.opencontainers.image.version=19.0.2)
2022-09-29T17:05:05.718178496Z network connect b4145308580fd568a5789e6f5345557a657c66187a05059e0e1d0e7d0813bab6 (container=48320d59a48b027ab5d08531271a2cd0c4cafac5e80f322fa7fc98c0849ba5b4, name=bridge, type=bridge)
2022-09-29T17:05:06.289309003Z container start 48320d59a48b027ab5d08531271a2cd0c4cafac5e80f322fa7fc98c0849ba5b4 (image=5d99cf30b3ae, name=cool_pasteur, org.opencontainers.image.authors=https://bitnami.com/contact, org.opencontainers.image.description=Application packaged by Bitnami, org.opencontainers.image.ref.name=19.0.2-debian-11-r4, org.opencontainers.image.source=https://github.com/bitnami/containers/tree/main/bitnami/keycloak, org.opencontainers.image.title=keycloak, org.opencontainers.image.vendor=VMware, Inc., org.opencontainers.image.version=19.0.2)
2022-09-29T17:05:12.038251773Z image tag sha256:5d99cf30b3aec76495a2db5b6e5292125f31f29ddfe7aca21789abd2f13fc30c (name=aws_beanstalk/current-app:latest, org.opencontainers.image.authors=https://bitnami.com/contact, org.opencontainers.image.description=Application packaged by Bitnami, org.opencontainers.image.ref.name=19.0.2-debian-11-r4, org.opencontainers.image.source=https://github.com/bitnami/containers/tree/main/bitnami/keycloak, org.opencontainers.image.title=keycloak, org.opencontainers.image.vendor=VMware, Inc., org.opencontainers.image.version=19.0.2)
2022-09-29T17:05:12.101612937Z image untag sha256:5d99cf30b3aec76495a2db5b6e5292125f31f29ddfe7aca21789abd2f13fc30c (name=sha256:5d99cf30b3aec76495a2db5b6e5292125f31f29ddfe7aca21789abd2f13fc30c, org.opencontainers.image.authors=https://bitnami.com/contact, org.opencontainers.image.description=Application packaged by Bitnami, org.opencontainers.image.ref.name=19.0.2-debian-11-r4, org.opencontainers.image.source=https://github.com/bitnami/containers/tree/main/bitnami/keycloak, org.opencontainers.image.title=keycloak, org.opencontainers.image.vendor=VMware, Inc., org.opencontainers.image.version=19.0.2)
2022-09-29T17:05:13.916310158Z image tag sha256:5d99cf30b3aec76495a2db5b6e5292125f31f29ddfe7aca21789abd2f13fc30c (name=aws_beanstalk/current-app:latest, org.opencontainers.image.authors=https://bitnami.com/contact, org.opencontainers.image.description=Application packaged by Bitnami, org.opencontainers.image.ref.name=19.0.2-debian-11-r4, org.opencontainers.image.source=https://github.com/bitnami/containers/tree/main/bitnami/keycloak, org.opencontainers.image.title=keycloak, org.opencontainers.image.vendor=VMware, Inc., org.opencontainers.image.version=19.0.2)
2022-09-29T17:05:14.010857853Z image tag sha256:2a52f7074b400c46837253be0cd6719054373aa15c556a2505cfc4875c732191 (name=bitnami/keycloak:19, org.opencontainers.image.authors=https://bitnami.com/contact, org.opencontainers.image.description=Application packaged by Bitnami, org.opencontainers.image.ref.name=19.0.2-debian-11-r4, org.opencontainers.image.source=https://github.com/bitnami/containers/tree/main/bitnami/keycloak, org.opencontainers.image.title=keycloak, org.opencontainers.image.vendor=VMware, Inc., org.opencontainers.image.version=19.0.2)
----------------------------------------
/var/log/eb-docker-process.log
----------------------------------------
2022/09/29 17:05:12.516005 [INFO] Loading Manifest...
2022/09/29 17:05:12.553556 [INFO] Running command /bin/sh -c /opt/aws/bin/cfn-get-metadata -s arn:aws:cloudformation:eu-west-2:882618350644:stack/awseb-e-2mwnvjecwe-stack/e6e0d050-3f75-11ed-a0e9-0a1f03d7e8a8 -r AWSEBAutoScalingGroup --region eu-west-2
2022/09/29 17:05:14.188072 [INFO] Running command /bin/sh -c /opt/aws/bin/cfn-get-metadata -s arn:aws:cloudformation:eu-west-2:882618350644:stack/awseb-e-2mwnvjecwe-stack/e6e0d050-3f75-11ed-a0e9-0a1f03d7e8a8 -r AWSEBBeanstalkMetadata --region eu-west-2
2022/09/29 17:05:15.706457 [INFO] Checking if docker is running...
2022/09/29 17:05:15.706480 [INFO] Fetch current app container id...
2022/09/29 17:05:15.706802 [INFO] Running command /bin/sh -c docker ps | grep 48320d59a48b
2022/09/29 17:05:15.851077 [INFO] 48320d59a48b 5d99cf30b3ae "/opt/bitnami/script…" 10 seconds ago Up 9 seconds 5000/tcp cool_pasteur
2022/09/29 17:05:15.851106 [INFO] Running command /bin/sh -c docker wait 48320d59a48b
----------------------------------------
/var/log/docker
----------------------------------------
Sep 29 17:04:41 ip-172-31-7-44 docker: time="2022-09-29T17:04:41.522348910Z" level=info msg="Starting up"
Sep 29 17:04:41 ip-172-31-7-44 docker: time="2022-09-29T17:04:41.546445360Z" level=info msg="parsed scheme: \"unix\"" module=grpc
Sep 29 17:04:41 ip-172-31-7-44 docker: time="2022-09-29T17:04:41.546469970Z" level=info msg="scheme \"unix\" not registered, fallback to default scheme" module=grpc
Sep 29 17:04:41 ip-172-31-7-44 docker: time="2022-09-29T17:04:41.546492925Z" level=info msg="ccResolverWrapper: sending update to cc: {[{unix:///run/containerd/containerd.sock <nil> 0 <nil>}] <nil> <nil>}" module=grpc
Sep 29 17:04:41 ip-172-31-7-44 docker: time="2022-09-29T17:04:41.546507007Z" level=info msg="ClientConn switching balancer to \"pick_first\"" module=grpc
Sep 29 17:04:41 ip-172-31-7-44 docker: time="2022-09-29T17:04:41.585273534Z" level=info msg="parsed scheme: \"unix\"" module=grpc
Sep 29 17:04:41 ip-172-31-7-44 docker: time="2022-09-29T17:04:41.585318052Z" level=info msg="scheme \"unix\" not registered, fallback to default scheme" module=grpc
Sep 29 17:04:41 ip-172-31-7-44 docker: time="2022-09-29T17:04:41.585339847Z" level=info msg="ccResolverWrapper: sending update to cc: {[{unix:///run/containerd/containerd.sock <nil> 0 <nil>}] <nil> <nil>}" module=grpc
Sep 29 17:04:41 ip-172-31-7-44 docker: time="2022-09-29T17:04:41.585350796Z" level=info msg="ClientConn switching balancer to \"pick_first\"" module=grpc
Sep 29 17:04:41 ip-172-31-7-44 docker: time="2022-09-29T17:04:41.870138260Z" level=info msg="Loading containers: start."
Sep 29 17:04:42 ip-172-31-7-44 docker: time="2022-09-29T17:04:42.576967756Z" level=info msg="Default bridge (docker0) is assigned with an IP address 172.17.0.0/16. Daemon option --bip can be used to set a preferred IP address"
Sep 29 17:04:42 ip-172-31-7-44 docker: time="2022-09-29T17:04:42.737972210Z" level=info msg="Loading containers: done."
Sep 29 17:04:43 ip-172-31-7-44 docker: time="2022-09-29T17:04:43.044803469Z" level=info msg="Docker daemon" commit=a89b842 graphdriver(s)=overlay2 version=20.10.17
Sep 29 17:04:43 ip-172-31-7-44 docker: time="2022-09-29T17:04:43.045249096Z" level=info msg="Daemon has completed initialization"
Sep 29 17:04:43 ip-172-31-7-44 docker: time="2022-09-29T17:04:43.082693306Z" level=info msg="API listen on /run/docker.sock"
Sep 29 17:05:03 ip-172-31-7-44 docker: time="2022-09-29T17:05:03.459921076Z" level=info msg="Layer sha256:35c7205075f4f3bd7f9b0e488668782fa244a75cccb6a6ef6a3b14251b55236d cleaned up"
----------------------------------------
/var/log/eb-engine.log
----------------------------------------
2022/09/29 17:05:11.511727 [INFO] Running command /bin/sh -c systemctl show -p PartOf nginx.service
2022/09/29 17:05:11.523154 [INFO] register process nginx
2022/09/29 17:05:11.523176 [INFO] Running command /bin/sh -c systemctl show -p PartOf nginx.service
2022/09/29 17:05:11.537946 [INFO] Running command /bin/sh -c systemctl daemon-reload
2022/09/29 17:05:11.659032 [INFO] Running command /bin/sh -c systemctl reset-failed
2022/09/29 17:05:11.666538 [INFO] Running command /bin/sh -c systemctl enable nginx.service
2022/09/29 17:05:11.786233 [INFO] Created symlink from /etc/systemd/system/multi-user.target.wants/nginx.service to /usr/lib/systemd/system/nginx.service.
2022/09/29 17:05:11.786293 [INFO] Running command /bin/sh -c systemctl show -p PartOf nginx.service
2022/09/29 17:05:11.802086 [INFO] Running command /bin/sh -c systemctl restart nginx.service
2022/09/29 17:05:11.904366 [INFO] Running command /bin/sh -c service iptables save
2022/09/29 17:05:11.966054 [INFO] iptables: Saving firewall rules to /etc/sysconfig/iptables: [ OK ]
2022/09/29 17:05:11.966069 [INFO] Traffic forward set-up completed.
2022/09/29 17:05:11.966074 [INFO] making STAGING app container current...
2022/09/29 17:05:11.966088 [INFO] Running command /bin/sh -c docker tag 5d99cf30b3ae aws_beanstalk/current-app
2022/09/29 17:05:12.041952 [INFO] Running command /bin/sh -c docker rmi aws_beanstalk/staging-app
2022/09/29 17:05:12.106692 [INFO] Untagged: aws_beanstalk/staging-app:latest
2022/09/29 17:05:12.106769 [INFO] Running command /bin/sh -c systemctl show -p PartOf eb-docker.service
2022/09/29 17:05:12.118591 [INFO] Running command /bin/sh -c systemctl daemon-reload
2022/09/29 17:05:12.242722 [INFO] Running command /bin/sh -c systemctl reset-failed
2022/09/29 17:05:12.250703 [INFO] Running command /bin/sh -c systemctl enable eb-docker.service
2022/09/29 17:05:12.365666 [INFO] Running command /bin/sh -c systemctl show -p PartOf eb-docker.service
2022/09/29 17:05:12.382129 [INFO] Running command /bin/sh -c systemctl is-active eb-docker.service
2022/09/29 17:05:12.390717 [INFO] Running command /bin/sh -c systemctl start eb-docker.service
2022/09/29 17:05:12.465476 [INFO] Running command /bin/sh -c systemctl show -p PartOf eb-docker-log.service
2022/09/29 17:05:12.479384 [INFO] Running command /bin/sh -c systemctl daemon-reload
2022/09/29 17:05:12.620319 [INFO] Running command /bin/sh -c systemctl reset-failed
2022/09/29 17:05:12.638521 [INFO] Running command /bin/sh -c systemctl enable eb-docker-log.service
2022/09/29 17:05:12.787312 [INFO] Created symlink from /etc/systemd/system/eb-docker.service.wants/eb-docker-log.service to /etc/systemd/system/eb-docker-log.service.
2022/09/29 17:05:12.787345 [INFO] Running command /bin/sh -c systemctl show -p PartOf eb-docker-log.service
2022/09/29 17:05:12.803790 [INFO] Running command /bin/sh -c systemctl is-active eb-docker-log.service
2022/09/29 17:05:12.814626 [INFO] Running command /bin/sh -c systemctl start eb-docker-log.service
2022/09/29 17:05:12.939662 [INFO] docker container 48320d59a48b is running aws_beanstalk/current-app
2022/09/29 17:05:12.939681 [INFO] Executing instruction: Clean up Docker
2022/09/29 17:05:12.939710 [INFO] Running command /bin/sh -c docker ps -aq
2022/09/29 17:05:13.129931 [INFO] 48320d59a48b
2022/09/29 17:05:13.129970 [INFO] Running command /bin/sh -c docker images | sed 1d
2022/09/29 17:05:13.282274 [INFO] aws_beanstalk/current-app latest 5d99cf30b3ae 10 seconds ago 622MB
bitnami/keycloak 19 2a52f7074b40 3 days ago 622MB
2022/09/29 17:05:13.282303 [INFO] save docker tag command: docker tag 5d99cf30b3ae aws_beanstalk/current-app:latest
2022/09/29 17:05:13.282309 [INFO] save docker tag command: docker tag 2a52f7074b40 bitnami/keycloak:19
2022/09/29 17:05:13.282321 [INFO] Running command /bin/sh -c docker rm `docker ps -aq`
2022/09/29 17:05:13.529450 [INFO] Error response from daemon: You cannot remove a running container 48320d59a48b027ab5d08531271a2cd0c4cafac5e80f322fa7fc98c0849ba5b4. Stop the container before attempting removal or force remove
2022/09/29 17:05:13.529511 [INFO] Running command /bin/sh -c docker rmi `docker images -aq`
2022/09/29 17:05:13.789049 [INFO] Error response from daemon: conflict: unable to delete 5d99cf30b3ae (cannot be forced) - image is being used by running container 48320d59a48b
Error response from daemon: conflict: unable to delete 2a52f7074b40 (cannot be forced) - image has dependent child images
2022/09/29 17:05:13.789067 [INFO] restore docker image name with command: docker tag 5d99cf30b3ae aws_beanstalk/current-app:latest
2022/09/29 17:05:13.789078 [INFO] Running command /bin/sh -c docker tag 5d99cf30b3ae aws_beanstalk/current-app:latest
2022/09/29 17:05:13.918414 [INFO] restore docker image name with command: docker tag 2a52f7074b40 bitnami/keycloak:19
2022/09/29 17:05:13.918438 [INFO] Running command /bin/sh -c docker tag 2a52f7074b40 bitnami/keycloak:19
2022/09/29 17:05:14.013863 [INFO] Executing instruction: start X-Ray
2022/09/29 17:05:14.013880 [INFO] X-Ray is not enabled.
2022/09/29 17:05:14.013885 [INFO] Executing instruction: configureSqsd
2022/09/29 17:05:14.013891 [INFO] This is a web server environment instance, skip configure sqsd daemon ...
2022/09/29 17:05:14.013896 [INFO] Executing instruction: startSqsd
2022/09/29 17:05:14.013900 [INFO] This is a web server environment instance, skip start sqsd daemon ...
2022/09/29 17:05:14.013905 [INFO] Executing instruction: Track pids in healthd
2022/09/29 17:05:14.013910 [INFO] This is an enhanced health env...
2022/09/29 17:05:14.013939 [INFO] Running command /bin/sh -c systemctl show -p ConsistsOf aws-eb.target | cut -d= -f2
2022/09/29 17:05:14.032650 [INFO] eb-docker.service healthd.service nginx.service eb-docker-events.service cfn-hup.service eb-docker-log.service docker.service
2022/09/29 17:05:14.032683 [INFO] Running command /bin/sh -c systemctl show -p ConsistsOf eb-app.target | cut -d= -f2
2022/09/29 17:05:14.055602 [INFO]
2022/09/29 17:05:14.057747 [INFO] Executing instruction: Configure Docker Container Logging
2022/09/29 17:05:14.066518 [INFO] Executing instruction: RunAppDeployPostDeployHooks
2022/09/29 17:05:14.066536 [INFO] Executing platform hooks in .platform/hooks/postdeploy/
2022/09/29 17:05:14.066560 [INFO] The dir .platform/hooks/postdeploy/ does not exist
2022/09/29 17:05:14.066564 [INFO] Finished running scripts in /var/app/current/.platform/hooks/postdeploy
2022/09/29 17:05:14.066572 [INFO] Executing cleanup logic
2022/09/29 17:05:14.068115 [INFO] Platform Engine finished execution on command: self-startup
2022/09/29 17:05:39.149172 [INFO] Starting...
2022/09/29 17:05:39.149959 [INFO] Starting EBPlatform-PlatformEngine
2022/09/29 17:05:39.149999 [INFO] reading event message file
2022/09/29 17:05:39.151835 [INFO] Engine received EB command cfn-hup-exec
2022/09/29 17:05:39.291599 [INFO] Running command /bin/sh -c /opt/aws/bin/cfn-get-metadata -s arn:aws:cloudformation:eu-west-2:882618350644:stack/awseb-e-2mwnvjecwe-stack/e6e0d050-3f75-11ed-a0e9-0a1f03d7e8a8 -r AWSEBAutoScalingGroup --region eu-west-2
2022/09/29 17:05:40.014546 [INFO] Running command /bin/sh -c /opt/aws/bin/cfn-get-metadata -s arn:aws:cloudformation:eu-west-2:882618350644:stack/awseb-e-2mwnvjecwe-stack/e6e0d050-3f75-11ed-a0e9-0a1f03d7e8a8 -r AWSEBBeanstalkMetadata --region eu-west-2
2022/09/29 17:05:40.681829 [INFO] checking whether command tail-log is applicable to this instance...
2022/09/29 17:05:40.681845 [INFO] this command is applicable to the instance, thus instance should execute command
2022/09/29 17:05:40.681850 [INFO] Engine command: (tail-log)
2022/09/29 17:05:40.682976 [INFO] Executing instruction: GetTailLogs
2022/09/29 17:05:40.682984 [INFO] Tail Logs...
2022/09/29 17:05:40.685700 [INFO] Running command /bin/sh -c tail -n 100 /var/log/eb-hooks.log
2022/09/29 17:05:40.687855 [INFO] Running command /bin/sh -c tail -n 100 /var/log/nginx/access.log
2022/09/29 17:05:40.689449 [INFO] Running command /bin/sh -c tail -n 100 /var/log/nginx/error.log
2022/09/29 17:05:40.693994 [INFO] Running command /bin/sh -c tail -n 100 /var/log/eb-docker/containers/eb-current-app/eb-48320d59a48b-stdouterr.log
2022/09/29 17:05:40.695588 [INFO] Running command /bin/sh -c tail -n 100 /var/log/docker-events.log
2022/09/29 17:05:40.702009 [INFO] Running command /bin/sh -c tail -n 100 /var/log/eb-docker-process.log
2022/09/29 17:05:40.703972 [INFO] Running command /bin/sh -c tail -n 100 /var/log/docker
2022/09/29 17:05:40.707914 [INFO] Running command /bin/sh -c tail -n 100 /var/log/eb-engine.log
The logs show that it is unable to delete the current docker images as the container is still running. I don't how I've caused that.
What is likely causing this?

vcluster development install: docker: unknown flag: --tag

I am setting up vcluster for development: docs
devspace run dev
....
[info] Using namespace 'vcluster'
[info] Using kube context 'vhost'
[done] √ Created namespace: vcluster
[info] Rebuild image because tag is missing
[info] Building image 'ghcr.io/loft-sh/loft-enterprise/dev-vcluster:kSukXFs' with engine 'buildkit'
[info] Execute BuildKit command with: docker buildx build --tag ghcr.io/loft-sh/loft-enterprise/dev-vcluster:kSukXFs --push --file Dockerfile --target builder -
unknown flag: --tag
See 'docker --help'.
Usage: docker [OPTIONS] COMMAND
...
Run 'docker COMMAND --help' for more information on a command.
To get more help with docker, check out our guides at https://docs.docker.com/go/guides/
[fatal] error building image ghcr.io/loft-sh/loft-enterprise/dev-vcluster:kSukXFs: exit status 125
Is my version of docker too old?
I am using Docker version 20.10.12

Unable to start container process: exec: "/bin/sh"

runc run failed: unable to start container process: exec: "/bin/sh": stat /bin/sh: no such file or directory
executor failed running [/bin/sh -c npm install --production #contrast/agent]: exit code: 1
I've encountered error above when running docker build script in cmd.
FYI, my docker file included "RUN npm install ..."
Here is my Dockerfile
and Here is the error output
Any idea on how to resolve this issue?

elasticbeanstalk deployment failing with Error response from daemon:

AWS Elastic Beanstalk failing with error response from daemon:
You cannot remove a running container c911e29b2ce2283bae300645bf2f034f7bf51c07b7ec72c6ebfa133d531a6129.
Stop the container before attempting removal or force remove
Error log bellow:
2020/04/26 07:15:31.279931 [INFO] Running command /bin/sh -c docker rmi `docker images -aq`
2020/04/26 07:15:31.369738 [ERROR] Error response from daemon: conflict: unable to delete 274bac0a2621 (cannot be forced) - image has dependent child images
Error response from daemon: conflict: unable to delete 6040329cd021 (cannot be forced) - image has dependent child images
Error response from daemon: conflict: unable to delete 1020a81a3f38 (cannot be forced) - image is being used by running container c911e29b2ce2
Error response from daemon: conflict: unable to delete 68e7be49c28c (cannot be forced) - image has dependent child images
2020/04/26 07:15:31.369787 [INFO] restore docker image name with command: docker tag 1020a81a3f38 aws_beanstalk/current-app:latest
2020/04/26 07:15:31.369804 [INFO] Running command /bin/sh -c docker tag 1020a81a3f38 aws_beanstalk/current-app:latest
2020/04/26 07:15:31.414707 [INFO] restore docker image name with command: docker tag 68e7be49c28c python:2.7
2020/04/26 07:15:31.414786 [INFO] Running command /bin/sh -c docker tag 68e7be49c28c python:2.7
2020/04/26 07:15:31.462282 [INFO] Running command /bin/sh -c /bin/file -m /opt/elasticbeanstalk/config/private/beanstalk-magic -b --mime-type /opt/elasticbeanstalk/deployment/app_source_bundle
2020/04/26 07:15:31.464666 [INFO] application/zip
2020/04/26 07:15:31.464679 [INFO] app source bundle is zip file ...
2020/04/26 07:15:31.464689 [INFO] extracting /opt/elasticbeanstalk/deployment/app_source_bundle to /var/app/current/
2020/04/26 07:15:31.464703 [INFO] Running command /bin/sh -c /usr/bin/unzip -q -o /opt/elasticbeanstalk/deployment/app_source_bundle -d /var/app/current/
2020/04/26 07:15:31.475355 [INFO] finished extracting /opt/elasticbeanstalk/deployment/app_source_bundle to /var/app/current/ successfully
2020/04/26 07:15:31.475367 [INFO] Executing instruction: RunPreBuildHooks
2020/04/26 07:15:31.475381 [INFO] The dir .platform/hooks/prebuild/ does not exist in the application. Skipping this step...
2020/04/26 07:15:31.475385 [INFO] Executing instruction: Docker Specific Build Application
2020/04/26 07:15:31.475404 [INFO] start build docker app
2020/04/26 07:15:31.475414 [INFO] fetch image name
2020/04/26 07:15:31.475437 [INFO] authenticate with ECR if the image is in an ECR repo
2020/04/26 07:15:31.475442 [INFO] pull docker image if update is not false in dockerrun.aws.json
2020/04/26 07:15:31.475455 [INFO] Running command /bin/sh -c docker pull node:alpine as builder
2020/04/26 07:15:31.516536 [ERROR] "docker pull" requires exactly 1 argument.
See 'docker pull --help'.
Usage: docker pull [OPTIONS] NAME[:TAG|#DIGEST]
Pull an image or a repository from a registry
2020/04/26 07:15:31.516557 [WARN] failed to execute command: docker pull node:alpine as builder, retrying...
2020/04/26 07:15:31.516577 [INFO] Running command /bin/sh -c docker pull node:alpine as builder
2020/04/26 07:15:31.557381 [ERROR] "docker pull" requires exactly 1 argument.
See 'docker pull --help'.
Usage: docker pull [OPTIONS] NAME[:TAG|#DIGEST]
Pull an image or a repository from a registry
2020/04/26 07:15:31.557405 [ERROR] An error occurred during execution of command [app-deploy] - [Docker Specific Build Application]. Stop running the command. Error: failed to pull docker image: Command /bin/sh -c docker pull node:alpine as builder failed with error exit status 1. Stderr:"docker pull" requires exactly 1 argument.
See 'docker pull --help'.
We had a problem like this on the following Platform: Docker running on 64bit Amazon Linux 2/3.0.0
Switching to Docker running on 64bit Amazon Linux/2.14.3 solved the problem - Docker image builds as expected.

In fabric first-network example, hot to fix the error: "transport: error while dialing: dial tcp: lookup peer0.org1.example.com: no such host"

Can't run the fabric first-network example
This is the log when I run: ./byfn up
/ ___| |_ _| / \ | _ \ |_ _|
\___ \ | | / _ \ | |_) | | |
___) | | | / ___ \ | _ < | |
|____/ |_| /_/ \_\ |_| \_\ |_|
Build your first network (BYFN) end-to-end test
Channel name : mychannel
Creating channel...
+ peer channel create -o orderer.example.com:7050 -c mychannel -f ./channel-artifacts/channel.tx --tls true --cafile /opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem
+ res=0
+ set +x
2019-06-27 22:22:11.117 UTC [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized
2019-06-27 22:22:12.361 UTC [cli.common] readBlock -> INFO 002 Received block: 0
===================== Channel 'mychannel' created =====================
Having all peers join the channel...
+ peer channel join -b mychannel.block
+ res=1
+ set +x
Error: error getting endorser client for channel: endorser client failed to connect to peer0.org1.example.com:7051: failed to create new connection: connection error: desc = "transport: error while dialing: dial tcp: lookup peer0.org1.example.com: no such host"
peer0.org1 failed to join the channel, Retry after 9 seconds
My environment:
Ubuntu 18.04
Docker version 18.06.1-ce, build e68fc7a
docker-compose version 1.24.0, build 0aa59064
go version go1.11.11 linux/amd64
echo $GOPATH results in /usr/local/go/bin
The peers should be able to join the channel
Try adding - GODEBUG=netdns=go in the environment section of peer-base.yaml file,it can be found in the fabric-samples/first-newtork/base/
This is a well known issue
inshort this caused due to changes to the file resolv.conf, the inter-container domain name resolution in Hyperledger Fabric is switched from the pure Go resolver to the cgo resolver, an SIGSEGV error caused by the known static link cgo is triggered, and thus the deployment of Hyperledger Fabric fails.
To know more follow this link.
this is the common problem, stop the network, remove all ur previous containers and prune the docker's volume, then restart the docker, finally re-run the network again:
$./byfn.sh down
$docker stop $(docker ps -a -q)
$docker rm $(docker ps -a -q)
$docker volume prune
$sudo systemctl daemon-reload
$sudo systemctl restart docker
$cd .....fabric-samples/first-network
$./byfn.sh -m generate
$./byfn.sh -m up
Solved it by running the examples in Ubuntu 16.04 LTS.
Prior I was trying it on Ubuntu 18.04, but the target OS for Hyperledger Fabric development was Ubuntu 16, not the brand new 18, so it makes sense that it runs smoothly in Ubuntu 16.

Resources