We're updating the issue view to help you get more done. 

The documentation for Installer does not work on Windows

Description

Hi,

Our cargo configuration makes use of the <zipUrlInstaller> to extract a working container. However, the configuration works with a Unix based systems but fails when executed on a Windows based system.

Here is the relevant cargo configuration:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 <plugin> <groupId>org.codehaus.cargo</groupId> <artifactId>cargo-maven2-plugin</artifactId> <configuration> <container> <containerId>tomcat6x</containerId> <zipUrlInstaller> <url>file://${settings.localRepository}/org/apache/tomcat/apache-tomcat/${tomcat.version}/apache-tomcat-${tomcat.version}.zip</url> <installDir>${project.build.directory}/container</installDir> </zipUrlInstaller> <dependencies> <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> </dependency> </dependencies> </container> <configuration> <home>${project.build.directory}/container/tomcat6x</home> <properties> <cargo.servlet.uriencoding>UTF-8</cargo.servlet.uriencoding> </properties> </configuration> </configuration> </plugin>

When executed on Windows, the following error occurs:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 [DEBUG] Configuring mojo 'org.codehaus.cargo:cargo-maven2-plugin:1.0.6:deploy' --> [DEBUG] (s) home = C:\Users\echiang\Projects\gliffy\src\release\online\target/container/tomcat6x [DEBUG] (s) properties = {cargo.servlet.uriencoding=UTF-8} [DEBUG] (f) configuration = org.codehaus.cargo.maven2.configuration.Configuration@651e95 [DEBUG] (s) containerId = tomcat6x [DEBUG] (s) url = file://C:/Users/echiang/.m2/repository/org/apache/tomcat/apache-tomcat/6.0.20/apache-tomcat-6.0.20.zip [DEBUG] (s) installDir = C:\Users\echiang\Projects\gliffy\src\release\online\target/container [DEBUG] (s) zipUrlInstaller = org.codehaus.cargo.maven2.configuration.ZipUrlInstaller@126ba64 [DEBUG] (s) groupId = mysql [DEBUG] (s) artifactId = mysql-connector-java [DEBUG] (s) dependencies = [org.codehaus.cargo.maven2.configuration.Dependency@182a033] [DEBUG] (f) container = org.codehaus.cargo.maven2.configuration.Container@e391c4 [DEBUG] (f) localRepository = Repository[local|file://C:\Users\echiang\.m2\repository] [DEBUG] (f) project = MavenProject: com.gliffy.online:gliffy-online:1.0-SNAPSHOT @ C:\Users\echiang\Projects\gliffy\src\release\online\pom .xml [DEBUG] (f) repositories = [Repository[gliffy|http://maven.gliffy.com/content/groups/public/], Repository[central|http://repo1.maven.org/m aven2]] [DEBUG] (f) settings = org.apache.maven.settings.Settings@1408a75 [DEBUG] (f) skip = false [DEBUG] -- end configuration -- [INFO] [cargo:deploy {execution: default-cli}] [INFO] ------------------------------------------------------------------------ [ERROR] FATAL ERROR [INFO] ------------------------------------------------------------------------ [INFO] Failed to download [file://C:/Users/echiang/.m2/repository/org/apache/tomcat/apache-tomcat/6.0.20/apache-tomcat-6.0.20.zip] [INFO] ------------------------------------------------------------------------ [DEBUG] Trace org.codehaus.cargo.container.ContainerException: Failed to download [file://C:/Users/echiang/.m2/repository/org/apache/tomcat/apache-tomcat/ 6.0.20/apache-tomcat-6.0.20.zip] at org.codehaus.cargo.container.installer.ZipURLInstaller.download(ZipURLInstaller.java:329) at org.codehaus.cargo.container.installer.ZipURLInstaller.install(ZipURLInstaller.java:148) at org.codehaus.cargo.maven2.configuration.Container.setupHome(Container.java:360) at org.codehaus.cargo.maven2.configuration.Container.createContainer(Container.java:241) at org.codehaus.cargo.maven2.AbstractCargoMojo.createNewContainer(AbstractCargoMojo.java:470) at org.codehaus.cargo.maven2.AbstractCargoMojo.createContainer(AbstractCargoMojo.java:410) at org.codehaus.cargo.maven2.AbstractDeployerMojo.doExecute(AbstractDeployerMojo.java:55) at org.codehaus.cargo.maven2.AbstractCargoMojo.execute(AbstractCargoMojo.java:268) at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138) at org.apache.maven.cli.MavenCli.main(MavenCli.java:362) at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) at org.codehaus.classworlds.Launcher.main(Launcher.java:375) Caused by: in cargo code: java.net.UnknownHostException: C at org.apache.tools.ant.taskdefs.Get.execute(Get.java:82) at org.codehaus.cargo.container.installer.ZipURLInstaller.doDownload(ZipURLInstaller.java:362) at org.codehaus.cargo.container.installer.ZipURLInstaller.download(ZipURLInstaller.java:310) ... 26 more Caused by: java.net.UnknownHostException: C at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:177) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366) at java.net.Socket.connect(Socket.java:525) at java.net.Socket.connect(Socket.java:475) at sun.net.NetworkClient.doConnect(NetworkClient.java:163) at sun.net.NetworkClient.openServer(NetworkClient.java:118) at sun.net.ftp.FtpClient.openServer(FtpClient.java:488) at sun.net.ftp.FtpClient.openServer(FtpClient.java:475) at sun.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.java:270) at org.apache.tools.ant.taskdefs.Get.doGet(Get.java:145) at org.apache.tools.ant.taskdefs.Get.execute(Get.java:78) ... 28 more in cargo code: java.net.UnknownHostException: C at org.apache.tools.ant.taskdefs.Get.execute(Get.java:82) at org.codehaus.cargo.container.installer.ZipURLInstaller.doDownload(ZipURLInstaller.java:362) at org.codehaus.cargo.container.installer.ZipURLInstaller.download(ZipURLInstaller.java:310) at org.codehaus.cargo.container.installer.ZipURLInstaller.install(ZipURLInstaller.java:148) at org.codehaus.cargo.maven2.configuration.Container.setupHome(Container.java:360) at org.codehaus.cargo.maven2.configuration.Container.createContainer(Container.java:241) at org.codehaus.cargo.maven2.AbstractCargoMojo.createNewContainer(AbstractCargoMojo.java:470) at org.codehaus.cargo.maven2.AbstractCargoMojo.createContainer(AbstractCargoMojo.java:410) at org.codehaus.cargo.maven2.AbstractDeployerMojo.doExecute(AbstractDeployerMojo.java:55) at org.codehaus.cargo.maven2.AbstractCargoMojo.execute(AbstractCargoMojo.java:268) at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138) at org.apache.maven.cli.MavenCli.main(MavenCli.java:362) at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) at org.codehaus.classworlds.Launcher.main(Launcher.java:375) Caused by: java.net.UnknownHostException: C at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:177) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366) at java.net.Socket.connect(Socket.java:525) at java.net.Socket.connect(Socket.java:475) at sun.net.NetworkClient.doConnect(NetworkClient.java:163) at sun.net.NetworkClient.openServer(NetworkClient.java:118) at sun.net.ftp.FtpClient.openServer(FtpClient.java:488) at sun.net.ftp.FtpClient.openServer(FtpClient.java:475) at sun.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.java:270) at org.apache.tools.ant.taskdefs.Get.doGet(Get.java:145) at org.apache.tools.ant.taskdefs.Get.execute(Get.java:78) ... 28 more --- Nested Exception --- java.net.UnknownHostException: C at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:177) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366) at java.net.Socket.connect(Socket.java:525) at java.net.Socket.connect(Socket.java:475) at sun.net.NetworkClient.doConnect(NetworkClient.java:163) at sun.net.NetworkClient.openServer(NetworkClient.java:118) at sun.net.ftp.FtpClient.openServer(FtpClient.java:488) at sun.net.ftp.FtpClient.openServer(FtpClient.java:475) at sun.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.java:270) at org.apache.tools.ant.taskdefs.Get.doGet(Get.java:145) at org.apache.tools.ant.taskdefs.Get.execute(Get.java:78) at org.codehaus.cargo.container.installer.ZipURLInstaller.doDownload(ZipURLInstaller.java:362) at org.codehaus.cargo.container.installer.ZipURLInstaller.download(ZipURLInstaller.java:310) at org.codehaus.cargo.container.installer.ZipURLInstaller.install(ZipURLInstaller.java:148) at org.codehaus.cargo.maven2.configuration.Container.setupHome(Container.java:360) at org.codehaus.cargo.maven2.configuration.Container.createContainer(Container.java:241) at org.codehaus.cargo.maven2.AbstractCargoMojo.createNewContainer(AbstractCargoMojo.java:470) at org.codehaus.cargo.maven2.AbstractCargoMojo.createContainer(AbstractCargoMojo.java:410) at org.codehaus.cargo.maven2.AbstractDeployerMojo.doExecute(AbstractDeployerMojo.java:55) at org.codehaus.cargo.maven2.AbstractCargoMojo.execute(AbstractCargoMojo.java:268) at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138) at org.apache.maven.cli.MavenCli.main(MavenCli.java:362) at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) at org.codehaus.classworlds.Launcher.main(Launcher.java:375)

Is there a configuration error here or is this an outstanding bug?

Thanks,
Eric

Status

Assignee

Savas Ali Tokmen

Reporter

Savas Ali Tokmen

Components

Fix versions

Affects versions

1.0.6

Priority

Major