6 Replies Latest reply on Feb 9, 2018 3:45 PM by shawkins

    Can not copy standalone directory to local machine - Teiid Docker quickstart

    shiloh.jordan

      I am getting error when trying to copy standalone directory to my local machine.  This is apart of the Teiid Docker quick-start example here: Quickstart example with Dockerized Teiid

       

      Steps I have taken:

      1.  I have downloaded the files from here :docker-quickstarts/data-federation  (this comes with data and VDB files required for the example)

      2. I changed to this directory - cd docker-quickstarts/data-federation

      3. downloaded the Teiid docker image using this command - docker pull teiid/teiid:8.10.0.Final 

      4.  started the Teiid docker image using this command - docker run -d --name=teiid810 teiid/teiid:8.10.0.Final 

      5.  Now, trying to copy the standalone directory to local machine using this command - docker cp teiid810:/opt/jboss/teiid-8.10.0.Final/standalone teiid810

       

       

      But I keep getting this error:

      Error response from daemon: Could not find the file /opt/jboss/teiid-8.10.0.Final/standalone in container teiid810

       

      All help is appreciated

       

      Thanks,
      Shiloh

        • 1. Re: Can not copy standalone directory to local machine - Teiid Docker quickstart
          shiloh.jordan

          So, it seems as though the 8.10.0.Final is unavailable on DockerHub

           

          When I pulled the 10.0.0.Final image and copied the standalone directory, it worked.

           

          Maybe the example should be updated to use more recent Docker image version (instead of 8.10.0.Final)

          • 2. Re: Can not copy standalone directory to local machine - Teiid Docker quickstart
            rareddy

            I would appreciate if you write an updated example. Instead of discussion choose article type, then you can submit an example.

            • 3. Re: Can not copy standalone directory to local machine - Teiid Docker quickstart
              shiloh.jordan

              Hi Ramesh,

              So,  unfortunately I have issues with 10.0.0.Final as well.
              I used this command to create Teiid instance that uses the externalized configuration directory created before.docker create --privileged=true -t -i -P -v /teiid10/standalone:/opt/jboss/teiid-10.0.0.Final/standalone -v :/opt/jboss/data-federation --name=teiid10 teiid/teiid:10.0.0.Final

               

               

              and when I went to start the container, I got following error:

               

               

              Unable to read the logging configuration from 'file:/opt/jboss/teiid-10.0.0.Final/standalone/configuration/logging.properties' (java.io.FileNotFoundException: /opt/jboss/teiid-10.0.0.Final/standalone/configuration/logging.properties (No such file or directory))

              java.lang.IllegalStateException: WFLYSRV0121: Configuration directory does not exist: /opt/jboss/teiid-10.0.0.Final/standalone/configuration

               

              Any thoughts?

              rareddy

              • 4. Re: Can not copy standalone directory to local machine - Teiid Docker quickstart
                rareddy

                Shiloh,

                 

                Have you done the copy of the configuration step? If yes, you should have a folder like "teiid810/standalone" on the local box you are running which contains the above file.

                 

                Ramesh..

                • 5. Re: Can not copy standalone directory to local machine - Teiid Docker quickstart
                  shiloh.jordan

                  Hi Ramesh,

                  8.10.0 Final - I pulled the docker image, I can successfully start the Teiid docker image but when trying to copy the configuration directory, I get this error:

                   

                  Error response from daemon: Could not find the file /opt/jboss/teiid-8.10.0.Final/standalone in container teiid810

                   

                  So I decided to try 10.0.0. Final - I pulled the docker image, I can successfully start the docker image and copy the configuration directory. I can successfully create Teiid instance that uses external standalone configuration directory

                  However, when I start this container, I get this:

                   

                  Unable to read the logging configuration from 'file:/opt/jboss/teiid-10.0.0.Final/standalone/configuration/logging.properties' (java.io.FileNotFoundException: /opt/jboss/teiid-10.0.0.Final/standalone/configuration/logging.properties (No such file or directory))

                  java.lang.IllegalStateException: WFLYSRV0121: Configuration directory does not exist: /opt/jboss/teiid-10.0.0.Final/standalone/configuration

                          at org.jboss.as.server.ServerEnvironment.<init>(ServerEnvironment.java:450)

                          at org.jboss.as.server.Main.determineEnvironment(Main.java:339)

                          at org.jboss.as.server.Main.main(Main.java:95)

                          at org.jboss.modules.Module.run(Module.java:344)

                          at org.jboss.modules.Main.main(Main.java:525)

                   

                  Not sure what to do from here? Is there a working docker image that I can use?

                  • 6. Re: Can not copy standalone directory to local machine - Teiid Docker quickstart
                    shawkins

                    Hi Shiloh,

                     

                    Some of what you are seeing is discussed on [TEIID-5131] Create ansible playbooks for the ansible service broker - JBoss Issue Tracker

                     

                    In short the base image that is produced by the project does have permission issues depending upon your docker or openshift environment. 

                     

                    If you are using openshift have a look at the Dockerfile under teiid-openshift-templates/server-docker at master · shawkins/teiid-openshift-templates · GitHub

                     

                    You can just customize that Dockerfile or create a Dockerfile that extends from the base and mimics the permission setting that is done as part of unpacking the distribution.  More than likely a change like that needs to be made for the base image.

                     

                    Steve