blueperf / acmeair-mainservice-java

This service contains the front end of AcmeAir Microservices.
Apache License 2.0
26 stars 88 forks source link

wget not found when building image with Dockerfile using latest Liberty image #18

Closed kathtsui closed 4 years ago

kathtsui commented 5 years ago

After following the instructions here: https://github.com/blueperf/acmeair-authservice-java/blob/master/Build_Instructions.md, I tried to build the image with command docker build - < Dockerfile and get an error /bin/sh: 1: wget: not found:

$ docker build - < Dockerfile
Sending build context to Docker daemon  3.584kB
Step 1/11 : FROM websphere-liberty:microProfile2
microProfile2: Pulling from library/websphere-liberty
9ff7e2e5f967: Pull complete 
59856638ac9f: Pull complete 
6f317d6d954b: Pull complete 
a9dde5e2a643: Pull complete 
650bbdf50d18: Pull complete 
016c8f81cbb1: Pull complete 
4a6152d46ddb: Pull complete 
fd1504308fc9: Pull complete 
957002e9f8c0: Pull complete 
4ac972625689: Pull complete 
21c944c600ac: Pull complete 
96bc0dc3c448: Pull complete 
6550c65c114b: Pull complete 
7f0e99039c01: Pull complete 
Digest: sha256:57cb4262aff7949702aeffea8e1479245a16045fb8ffb792a7f1ca38216f1f81
Status: Downloaded newer image for websphere-liberty:microProfile2
 ---> 8acc64c44c06
Step 2/11 : RUN wget -t 10 -x -nd -P /opt/ibm/wlp/usr https://github.com/WASdev/sample.opentracing.zipkintracer/releases/download/1.3/liberty-opentracing-zipkintracer-1.3-sample.zip && cd /opt/ibm/wlp/usr && unzip liberty-opentracing-zipkintracer-1.3-sample.zip && rm liberty-opentracing-zipkintracer-1.3-sample.zip
 ---> Running in 02f84cd56c5a
/bin/sh: 1: wget: not found
The command '/bin/sh -c wget -t 10 -x -nd -P /opt/ibm/wlp/usr https://github.com/WASdev/sample.opentracing.zipkintracer/releases/download/1.3/liberty-opentracing-zipkintracer-1.3-sample.zip && cd /opt/ibm/wlp/usr && unzip liberty-opentracing-zipkintracer-1.3-sample.zip && rm liberty-opentracing-zipkintracer-1.3-sample.zip' returned a non-zero code: 127

Checking with @jnativio, he found that the problem seems that the new image for liberty does not have wget

I have tried the following branches and see the same wget issue: master microprofile-1.3 microprofile-2.0

I suspect all branches using the latest Liberty image are affected.

Opening this issue for blueperf to fix the Dockerfile with the latest Liberty image.

jnativio commented 5 years ago

@jdmcclur Do you know why latest images of liberty don't contain wget or unzip?

kathtsui commented 5 years ago

@jdmcclur @jnativio Looks like unzip issue in our tests is coming from our jmeter image after further investigation.

For liberty image, wget not found is definitely causing an issue when using the Dockerfile shipped in blueperf. We can take unzip out of this issue.

jdmcclur commented 5 years ago

@kathtsui - Hello, If you don't need micro-climate support, use Dockerfile-base to build your images. Dockerfile will be fixed soon (I hope), there are a couple other issues with it.

@jnativio - wget and unzip were taken out for security reasons, which is making things annoying, you may need to update your dockerfiles for istio also.

kathtsui commented 5 years ago

@jdmcclur I can confirm that using Dockerfile-base works for creating image for acmeair.

@jnativio I'll wait for your fix for Dockerfile-istio. Currently we can use our last working image from registry for our test but we will need to be able to create image in future.

Thank you, all.

jdmcclur commented 5 years ago

The normal Dockerfile should work now.