Questions Tagged With dockerhttps://answers.axonivy.com/tags/docker/?type=rssquestions tagged <span class="tag">docker</span>enTue, 30 Jun 2020 00:38:52 -0400Config ivy log in GCPhttps://answers.axonivy.com/questions/4623/config-ivy-log-in-gcp<h2>Dear ivy team support,</h2> <p>Currently, I'm doing some configuration for the ivy log in GCP environment. Here is my config:</p> <hr> <pre><code> &lt;appender name="ConsoleAppender" class="org.apache.log4j.ConsoleAppender"&gt; &lt;param name="Threshold" value="INFO"/&gt; &lt;param name="Target" value="System.out" /&gt; &lt;layout class="ch.ivyteam.log.layout.IvyLog4jLayout"&gt; &lt;param name="DateFormat" value="yyyy-MM-dd HH:mm:ss.SSS"/&gt; &lt;/layout&gt; &lt;filter class="org.apache.log4j.varia.LevelRangeFilter"&gt; &lt;param name="LevelMin" value="INFO"/&gt; &lt;param name="LevelMax" value="WARN"/&gt; &lt;param name="AcceptOnMatch" value="true"/&gt; &lt;/filter&gt; &lt;/appender&gt; &lt;!-- appender that writes log messages with priority ERROR or higher to stderr --&gt; &lt;appender name="ConsoleAppenderError" class="org.apache.log4j.ConsoleAppender"&gt; &lt;param name="Threshold" value="ERROR"/&gt; &lt;param name="Target" value="System.err" /&gt; &lt;layout class="ch.ivyteam.log.layout.IvyLog4jLayout"&gt; &lt;param name="DateFormat" value="yyyy-MM-dd HH:mm:ss.SSS"/&gt; &lt;/layout&gt; &lt;/appender&gt; &lt;!-- Disable CXF warning at startup (missing META-INF/cxf/cxf.xml) --&gt; &lt;category name="org.apache.cxf.bus.spring" class="ch.ivyteam.log.Logger"&gt; &lt;priority value="ERROR"/&gt; &lt;/category&gt; </code></pre> <hr> <p>But I got the problem: With the exception, it will print each line of exception in the stackDriver log like this picture:</p> <p><img src="https://serving.photos.photobox.com/28132375a8296995992fcbb28aeb802497fe58244761b0962f9f3903c8a51ecd38b4598a.jpg"></p> <hr> <p>We use fluentd and Stackdriver to display the log. <br> As I understood, we have 2 steps to display the log in the GCP <br></p> <ol> <li>Step 1: Base on the configuration in the log4jconfig.xml, Ivy will print the log to the console with the corresponding format so that fluentd can read it and display in the log view<br></li> <li>Step 2: fluentd will read that log and display in the log view.<br></li> </ol> <p>When I check step 2, it is correct because the fluentd displayed exactly the result of step 1. <br> But step 1 got a problem, it prints incorrectly the entry log. I have 1 block exception but it prints to multiline log entries. <br> My expectation: each exception case will be visualized by only 1 entry log so that developer can easier trace the exception reason and find the solution. <br> Could you please give me some advice? <br></p> <p>Thank you</p>nndiemTue, 30 Jun 2020 00:38:52 -0400https://answers.axonivy.com/questions/4623/config-ivy-log-in-gcpdockerWhere does Axon.ivy Engine 8 store deployed files?https://answers.axonivy.com/questions/4600/where-does-axon-ivy-engine-8-store-deployed-files<p>Hi Ivy Team,</p> <p>Axon.ivy Engine 8 comes with different deployment behavior. To keep the state of Ivy Application running on Container, I need to know where does it store deployed files, to mount those paths into persistent volumes.</p> <p>In other word, how many places I need to mount into persistent volumes to make Axon.ivy works on Container environment?</p>vinh_Fri, 19 Jun 2020 01:24:49 -0400https://answers.axonivy.com/questions/4600/where-does-axon-ivy-engine-8-store-deployed-filesenginedockerivyEngine Docker contrainer startup failure MAChttps://answers.axonivy.com/questions/4377/engine-docker-contrainer-startup-failure-mac<p>Hello,</p> <p>I'm using a MAC and I try to start a docker engine image First I pull the image using this command : docker pull axonivy/axonivy-engine, and then I try to run with this command : docker run -p 8080:8080 axonivy/axonivy-engine, but when I execute it I get the following error: /usr/lib/axonivy-engine/bin/docker-entrypoint.sh: line 11: /usr/lib/axonivy-engine-9/bin/AxonIvyEngine: No such file or directory I checked in my /usr/lib and I don't have any axonivy-engine nor axonivy-engine-9 folders</p>MariusFri, 07 Feb 2020 01:47:55 -0500https://answers.axonivy.com/questions/4377/engine-docker-contrainer-startup-failure-macdockerAxon ivy Docker Java referenced class not found exceptionhttps://answers.axonivy.com/questions/4203/axon-ivy-docker-java-referenced-class-not-found-exception<p>Hi Ivy team,</p> <p>I use axon ivy version 7.3.1(Designer and Engine), maven 3.6.2 I've create a dialog form with "add new" button, when user click that button, it will call a method in Java class.</p> <p>after run and build with maven, I have a <strong>"xxx-app-1.0.0-SNAPSHOT.iar"</strong>. </p> <p>I copy this file to deploy folder of <strong>"AxonIvyEngine7.3.1.1904101154_All_x64"</strong> and run Engine and then run web app . everything is ok when I click "add new" button</p> <p>But when I copy that file :<strong>"xxx-app-1.0.0-SNAPSHOT.iar"</strong> in docker file :</p> <pre><code> FROM axonivy/axonivy-engine:7.3.1 LABEL maintainer="xxxx@abc.com" COPY --chown=ivy:ivy target/xxx-app-1.0.0-SNAPSHOT.iar deploy/ ( this command will copy xxx-app-1.0.0-SNAPSHOT.iar to deploy folder on container ) EXPOSE 8080 </code></pre> <p>and then I create a docker-compose file </p> <pre><code>version: '3.3' services: axonivy-engine: image: my-app-test build: . ports: - 8082:8080 restart: always </code></pre> <ul> <li>Run docker-compose up</li> <li>Run web app and then click "add new" button. I've get a errors:</li> </ul> <p>Errorrs:</p> <pre><code>Caused by: ch.ivyteam.ivy.scripting.exceptions.classDef.ReferencedClassNotFoundException: Referenced class 'com/axonivy/persistence/beans/GenericEntity' not found for class 'controller.AddNew' </code></pre> <p>I don't why with same a file <strong>IAR</strong> but when I run it on local it run well and doesn't through any errors .But after run from <strong>docker container</strong> the UI still appear ok, but when user click button, it call method in java class then through errors</p> <p>I've check in zip file on <strong>"work"</strong> folder in Engine in docker container it still exist all file java class</p> <p>can you guy help me please </p> <p>my iar file:</p> <p><a href="https://answers.axonivy.com/upfiles/my-app-1.0.0-SNAPSHOT.png">link text</a></p>tuannvWed, 27 Nov 2019 02:44:21 -0500https://answers.axonivy.com/questions/4203/axon-ivy-docker-java-referenced-class-not-found-exceptiondockerI can't integrated axon-ivy engine with window nano server code in a image on dockerhttps://answers.axonivy.com/questions/4174/i-can-t-integrated-axon-ivy-engine-with-window-nano-server-code-in-a-image-on-docker<p>Dear Ivy team, </p> <p>I use window 10 and installed Docker tool. <img alt="alt text" src="https://answers.axonivy.com/upfiles/KjGEs_baJ1saX.png"></p> <p>Because our axon ivy's project use <strong>axon-ivy engine</strong> 7.0.1. it have some <strong>lib call from window's library</strong>. So I have to create a image can run on <strong>linux container</strong> and still call lib of window OS success</p> <p>I use Docker to build a image include axon-ivy engine and window core in docker hub:</p> <p>my docker file is:</p> <pre><code>FROM mcr.microsoft.com/windows/nanoserver:1903 FROM dgauch/axonivy-engine:7.0.1 Expose 8082 </code></pre> <p>I use one of window docker hubs : 1. microsoft/windowscore 2. microsoft/nanoserver</p> <p>But I only can run "<strong>dgauch/axonivy-engine</strong>" if I switched to docker linux container then can't run mcr.microsoft.com/windows/servercore:ltsc2019 there is a error: no matching manifest for linux/amd64 in the manifest list entries.</p> <p>When I switched to window container at docker tool desktop. I can run mcr.microsoft.com/windows/nanoserver:1909 is succesful.</p> <p>but there are error when run docker for <strong>dgauch/axonivy-engine</strong>. There are a error: image operating system "linux" cannot be used on this platform</p> <p>How can I do integrate two image axon-ivy engine and window core to a image, that can run every where on linux or window system ?</p>tuannvWed, 20 Nov 2019 02:57:11 -0500https://answers.axonivy.com/questions/4174/i-can-t-integrated-axon-ivy-engine-with-window-nano-server-code-in-a-image-on-dockerdockerHow to override underscore global variables with environment variables?https://answers.axonivy.com/questions/4168/how-to-override-underscore-global-variables-with-environment-variables<p>Dear Ivy team, We are following <a href="https://developer.axonivy.com/doc/latest/engine-guide/configuration/index.html#overriding-configuration">this guideline</a> to override global variables in order to dockerize our ivy engine. But there is a problem, if the variable key contains underscores (For example: <code>ch_xpertline_luz_support_username</code>), the ivy will replace all underscores by dots !!</p> <p>Do you have any idea that helps us to overcome this situation? Thank you!</p>an_nguyenThu, 14 Nov 2019 06:02:21 -0500https://answers.axonivy.com/questions/4168/how-to-override-underscore-global-variables-with-environment-variablesdockerglobalvariableDocker, global variables, app.yamlhttps://answers.axonivy.com/questions/4162/docker-global-variables-app-yaml<p>Dear Ivy Team</p> <p>It looks like there are 3 places where the global vars can be set : - inside IAR - in DB - in app.yaml</p> <p>So what is the order how Ivy is looking for the global vars ?</p> <p>Thanks &amp; Regards, John Moser</p>John MoserTue, 12 Nov 2019 03:57:38 -0500https://answers.axonivy.com/questions/4162/docker-global-variables-app-yamldockerglobalvariableDocker, applications folder, deploymenthttps://answers.axonivy.com/questions/4154/docker-applications-folder-deployment<p>Dear Ivy team</p> <p>When we are building the KLARA image in windows, we get an issue with long file names. We have decided to keep the deployed IARs inside the image. Therefore the deployed apps are part of it. The folder structure looks like this :</p> <pre><code>jam:~/.../applications/luz$ ls -ltr total 80 drwxr-xr-x 3 jam jam 4096 Mai 1 2019 luz_components drwxr-xr-x 3 jam jam 4096 Mai 1 2019 luz_docs_process drwxr-xr-x 3 jam jam 4096 Mai 1 2019 luz_finance drwxr-xr-x 3 jam jam 4096 Mai 1 2019 luz_xhrm_processes </code></pre> <p>and each folder contains all the Ivy stuff. So no wonder build under Windows is an issue due to long file names.</p> <p>Question : What is needed in these folders ? can we skip some folders/files ?</p> <p>Request for 7.3.2 : Can you provide a "applications"-less Ivy version which does not require 7.4 ? </p> <p>Best regards John Moser</p>John MoserFri, 08 Nov 2019 02:34:12 -0500https://answers.axonivy.com/questions/4154/docker-applications-folder-deploymentdockerdeploymentDocker container can't apply IAR newesthttps://answers.axonivy.com/questions/4146/docker-container-can-t-apply-iar-newest<p>Hi Ivy Team.</p> <p>I'm using axon ivy designer and engine. both of them user version 7.4.0 I create a dialog mytest and deploy int to folder deloyed in axon iv deploy It's success</p> <p>but now I use docker to create a docker file and and then create a docker container base on that docker image docker ifle:</p> <pre><code>FROM axonivy/axonivy-engine:7.4.0 MAINTAINER Vantuan, tuan.nguyen@axonactive.com RUN mkdir -p E:/Axon7.4/AxonIvyDesigner7.4.0.1909161423_Windows_x64/workspace/mytest/Portal/ RUN chmod 775 deploy ADD target/*.iar E:/Axon7.4/AxonIvyDesigner7.4.0.1909161423_Windows_x64/workspace/mytest/Portal/ ADD target/mytest-1.0.0-SNAPSHOT.iar deploy EXPOSE 8080 </code></pre> <p>after create docker container I run on browser, it only show engine server example, don't show <code>mytest.iar</code></p> <p>with error:</p> <pre><code>axonivy-engine_1 | [ 75%] Background Jobs Stopper started [0ms] axonivy-engine_1 | 01:59:33.338 ERROR [....ivy.deployment.internal.auto.scanner] [Deployment Queue] axonivy-engine_1 | '/var/lib/axonivy-engine-7x/deploy/mytest-1.0.0-SNAPSHOT.iar' not deployed. This file is not writable. </code></pre>tuannvWed, 06 Nov 2019 22:02:32 -0500https://answers.axonivy.com/questions/4146/docker-container-can-t-apply-iar-newestdockerDocker, set permissions by yaml filehttps://answers.axonivy.com/questions/4001/docker-set-permissions-by-yaml-file<p>Hi Ivy Team</p> <p>Is it possible to configure the permissions also by a yaml file ?</p> <p>Regards John</p>John MoserThu, 19 Sep 2019 11:10:44 -0400https://answers.axonivy.com/questions/4001/docker-set-permissions-by-yaml-filedockerivyDocker, pass Ivy license as env prophttps://answers.axonivy.com/questions/3999/docker-pass-ivy-license-as-env-prop<p>Dear Ivy team</p> <p>Is it possible to pass the Ivy license via env prop ? </p> <p>Reason for my question : as you might know we in KLARA want to build our own image. If the license has to be provided as a file in a certain directory then our image, which is hosted somewhere in the cloud, contains the license. May be not so nice from your point of view.</p> <p>The idea is that we store the license as a secret and inject it at startup of the image.</p> <p>Regards John</p>John MoserThu, 19 Sep 2019 04:51:42 -0400https://answers.axonivy.com/questions/3999/docker-pass-ivy-license-as-env-propdockerivylicenseDocker, Migration 7.2.1 to 7.3.1https://answers.axonivy.com/questions/3952/docker-migration-7-2-1-to-7-3-1<p>Hi Ivy Team</p> <p>I am getting following error message during Ivy startup after I migrated to the 7.3.1 image :</p> <p>java.lang.Exception: The system database (jdbc:<a>postgresql://10.172.0.9:5432/ivysystemdb_7)</a> with all tables already exists (Version: 50). But was created with a older version of the ivy Engine. at ch.ivyteam.ivy.server.configuration.command.CreateDbCommand.checkIfCreationNeeded(CreateDbCommand.java:114) at ch.ivyteam.ivy.server.configuration.command.CreateDbCommand.createSystemDatabase(CreateDbCommand.java:63) at ...</p> <p>What has to be done to fix this problem.</p> <p>Thanks &amp; Regards John</p>John MoserThu, 29 Aug 2019 10:33:45 -0400https://answers.axonivy.com/questions/3952/docker-migration-7-2-1-to-7-3-1enginedockerivyDocker, set admin client / system db values via yaml filehttps://answers.axonivy.com/questions/3892/docker-set-admin-client-system-db-values-via-yaml-file<p>Dear Ivy Team</p> <p>In the Non-Docker world, we have a deployment IAR, which writes config values fed via a script.</p> <p>With Docker we want to avoid that. The global variables we already configure them via app.yaml. What would be (in the future ?) the best way to configure permissions, iwa_applicationproperty, etc</p> <p>Best regards, John</p>John MoserTue, 16 Jul 2019 11:34:51 -0400https://answers.axonivy.com/questions/3892/docker-set-admin-client-system-db-values-via-yaml-filedockerDocker, Rerun image with IAR installationhttps://answers.axonivy.com/questions/3891/docker-rerun-image-with-iar-installation<p>Dear Ivy Team</p> <p>In your example setup, the ivysystemdb exists as an image and is therefore created from scratch every time docker-compose is run. That means you can run the same image as many times as you want.</p> <p>If we do that in our Dev environment, we are running into the versioning problem (I think), which prevents to rerun of the same image multiple times (Error : The process model version '1' of process model 'luz_web' of application 'luz' is currently unavailable because of maintenance.) </p> <p>Since our image does the installation as well, it can't be "used" more then one time, which means for each restart we would need a new build of a new version of our app.</p> <p>Or do I miss something ?</p> <p>Best regards John</p>John MoserMon, 15 Jul 2019 12:20:24 -0400https://answers.axonivy.com/questions/3891/docker-rerun-image-with-iar-installationdockerDocker, dropins, AuthenticationValvehttps://answers.axonivy.com/questions/3831/docker-dropins-authenticationvalve<p>Hi Ivy Team</p> <p>I am building a Docker image based on axonivy/axonivy-engine:7.2.1. In our project we have a few JARs which should go into the dropins folder but during Ivy startup I get the following error :</p> <pre><code>14:13:05.368 ERROR [org.apache.tomcat.util.digester.Digester] [localhost-startStop-1] Begin event threw exception java.lang.ClassNotFoundException: com.axonivy.auth.valve.AuthenticationValve cannot be found by ch.ivyteam.tomcat_8.5.34.201810151000 ... 4:13:05.380 ERROR [...apache.catalina.startup.ContextConfig] [localhost-startStop-1] Parse error in context.xml for [/ivy] org.xml.sax.SAXParseException; systemId: file:/usr/lib/axonivy-engine-7x/webapps/ivy/META-INF/context.xml; lineNumber: 13; columnNumber: 66; Error at (13, 66) : com.axonivy.auth.valve.AuthenticationValve cannot be found by ch.ivyteam.tomcat_8.5.34.201810151000 </code></pre> <p>So far I did the following:</p> <p>1) Dockerfile:</p> <pre><code>COPY --chown=ivy:ivy axonivy7-engine-folder-setup/dropins/* /usr/lib/axonivy-engine-7x/dropins/ </code></pre> <p>2) Check if files exist after Ivy startup:</p> <pre><code>ivy@22ae6389e9e5:/usr/lib/axonivy-engine-7x/dropins$ ls -ltr total 956 -rwxr-xr-x 1 ivy ivy 2028 Mar 8 2018 README.html -rwxr-xr-x 1 ivy ivy 962431 Jul 19 2018 com.axonivy.auth.valve.AuthenticationValve_1.0.0.201807190929.jar -rwxr-xr-x 1 ivy ivy 1622 Aug 1 2018 workflow.klara_patchNoBusinessCaseQuery_1.0.0.201807311434.jar -rw-r--r-- 1 ivy ivy 8078 Nov 5 2018 webserver.rest.extension.patch_1.0.0.201805241153.jar </code></pre> <p>3) Check if JARs are listed using ss in console, but all the JARs in dropins are not listed:</p> <p>Axon.ivy Engine is running and ready to serve. [19778ms] Type 'shutdown' and confirm with ENTER to stop the running engine instance ss "Framework is launched."</p> <pre><code>id State Bundle 0 ACTIVE org.eclipse.osgi_3.13.0.v20180409-1500 Fragments=2, 1 1 RESOLVED ch.ivyteam.ivy.osgi.classpatcher_7.2.1.201811131504 Master=0 2 RESOLVED org.eclipse.osgi.compatibility.state_1.1.100.v20180331-1743 Master=0 3 ACTIVE org.eclipse.equinox.simpleconfigurator_1.3.0.v20180502-1828 </code></pre> <p>As far as I understood, one should copy the JARs into the dropins folder and it should work</p> <p>Thanks &amp; Regards John</p>John MoserFri, 31 May 2019 10:29:36 -0400https://answers.axonivy.com/questions/3831/docker-dropins-authenticationvalvedockerconfigurationivyDocker, Global Properties, Placeholder, app.yamlhttps://answers.axonivy.com/questions/3817/docker-global-properties-placeholder-app-yaml<p>Hi Ivy Team</p> <p>Assuming I have a global prop such as :</p> <p>myGlobalProp: <a href="http://myIP:1234/whatever">http://myIP:1234/whatever</a></p> <p>myIP is different for Dev, Test and Prod. Is there a way to "inject" myIP at startup of the Docker image ?</p> <p>Or generally:</p> <p>If I want to build an image which should be deployed in Dev, Test and Prod, is there a way to parameterize all the config files used for the Ivy Engine (yaml, xml, etc.) ?</p> <p>Thanks &amp; Regards John</p>John MoserMon, 20 May 2019 11:20:27 -0400https://answers.axonivy.com/questions/3817/docker-global-properties-placeholder-app-yamlenginedockerconfigurationivyDocker, prevent container being stopped after an exceptionhttps://answers.axonivy.com/questions/3802/docker-prevent-container-being-stopped-after-an-exception<p>Hi Ivy team</p> <p>Is there a switch or something to keep the container running even if there was a (fatal) exception at boot time of Ivy ?</p> <p>Currently it's slightly painful to debug ...</p> <p>Thanks &amp; Regards John Moser</p>John MoserWed, 15 May 2019 11:54:13 -0400https://answers.axonivy.com/questions/3802/docker-prevent-container-being-stopped-after-an-exceptiondockerivyDocker, Dockerfile, what USER to applyhttps://answers.axonivy.com/questions/3801/docker-dockerfile-what-user-to-apply<p>Hi Ivy team</p> <p>We want to build our own image and we are running in some troubles regarding the USER :</p> <p>FROM axonivy/axonivy-engine:7.2.1</p> <p>USER root or ivy or ... ? &lt;--- which one to apply ?</p> <p>COPY ... CMD ... etc.</p> <p>Thanks &amp; Regards John Moser</p> <p>PS: can someone with enough "reputation" put dockerfile into the tag list ?</p>John MoserWed, 15 May 2019 11:25:17 -0400https://answers.axonivy.com/questions/3801/docker-dockerfile-what-user-to-applydockerdockerfileDocker, IAR deploymenthttps://answers.axonivy.com/questions/3800/docker-iar-deployment<p>Hi Ivy team</p> <p>I have a zip file with IARs (but w/o app.yaml) and I use COPY to copy the zip file to the deploy folder of the Ivy engine, where it should be deployed at startup - according to the doc.</p> <p>a) is this procedure correct ? b) If yes then I get -&gt; Caused by: java.nio.file.FileSystemNotFoundException: /usr/lib/axonivy-engine-7x/applications/projects/authentication_tool_ivy/1.zip</p> <p>There is indeed a authentication_tool_ivy-7.2.0-SNAPSHOT.iar in the zip file.</p> <p>Any idea why this error happens ? Any more specific description how the files have to be named ? Is the order how the IARs are listed in the zip file relevant ?</p> <p>Thanks &amp; Regards John Moser</p>John MoserWed, 15 May 2019 11:10:37 -0400https://answers.axonivy.com/questions/3800/docker-iar-deploymentdockerdeploymentIs there anyway to run Ivy Designer 7.0 on MacOS?https://answers.axonivy.com/questions/3156/is-there-anyway-to-run-ivy-designer-7-0-on-macos<p>Hello Support Team,</p> <p>I'm an Ivy Developer for years, like other developers, I refer Linux or MacOS rather than Windows. I have many useful command line tools that Windows is missing. I'm happy that you still release an unofficial Linux version of Ivy Designer and it works really well (except WebEditor). It would be great if I can run a MacOS version of Ivy Designer, is there any chance for me?</p> <p>UPDATE:</p> <ul> <li>You can run AxonIvy Designer 7.0 on Docker: <a href="https://github.com/cavoirom/axonivy-designer">https://github.com/cavoirom/axonivy-designer</a></li> <li>For 7.3 and newer there exist an official beta: <a href="https://answers.axonivy.com/questions/3664/official-mac-designer-beta-experience">https://answers.axonivy.com/questions/3664/official-mac-designer-beta-experience</a></li> </ul>vinh_Wed, 28 Mar 2018 14:13:47 -0400https://answers.axonivy.com/questions/3156/is-there-anyway-to-run-ivy-designer-7-0-on-macosdockerdesignerivy