$ cd ~/.ZAP
$ pwd
$ cd ~/.ZAP_D
$ pwd
[ZAP Jenkins Plugin] CONFIGURE RUN COMMANDS for [ /opt/ZAP/ZAP_D-2017-03-21/zap.sh ] [ZAP Jenkins Plugin] EXECUTE LAUNCH COMMAND [ZAP_D-2017-03-21] $ /opt/ZAP/ZAP_D-2017-03-21/zap.sh -daemon -host 127.0.0.1 -port 8055 -config api.key=ZAPROXY-PLUGIN -dir /opt/ZAP/ZAP_D-2017-03-21 -installdir $ZAPROXY_HOME [ZAP Jenkins Plugin] INITIALIZATION [ START ] Found Java version 1.8.0_92 Available memory: 3832 MB Setting jvm heap size: -Xmx958m Unable to initialize home directory! /opt/ZAP/ZAP_D-2017-03-21/log4j.properties (Permission denied) java.io.FileNotFoundException: /opt/ZAP/ZAP_D-2017-03-21/log4j.properties (Permission denied) at java.io.FileOutputStream.open0(Native Method) at java.io.FileOutputStream.open(FileOutputStream.java:270) at java.io.FileOutputStream.<init>(FileOutputStream.java:213) at java.io.FileOutputStream.<init>(FileOutputStream.java:162) at org.parosproxy.paros.model.FileCopier.copyLegacy(FileCopier.java:52) at org.parosproxy.paros.model.FileCopier.copy(FileCopier.java:44) at org.parosproxy.paros.Constant.initializeFilesAndDirectories(Constant.java:418) at org.parosproxy.paros.Constant.<init>(Constant.java:319) at org.parosproxy.paros.Constant.createInstance(Constant.java:903) at org.parosproxy.paros.Constant.getInstance(Constant.java:895) at org.zaproxy.zap.ZapBootstrap.start(ZapBootstrap.java:76) at org.zaproxy.zap.DaemonBootstrap.start(DaemonBootstrap.java:48) at org.zaproxy.zap.ZAP.main(ZAP.java:98) ERROR: java.net.ConnectException: Connection refused at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350) at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206) at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) at java.net.Socket.connect(Socket.java:589) at org.jenkinsci.plugins.zap.ZAPDriver.waitForSuccessfulConnectionToZap(ZAPDriver.java:728) at org.jenkinsci.plugins.zap.ZAPDriver.access$100(ZAPDriver.java:104) at org.jenkinsci.plugins.zap.ZAPDriver$WaitZAPDriverInitCallable.invoke(ZAPDriver.java:2537) at org.jenkinsci.plugins.zap.ZAPDriver$WaitZAPDriverInitCallable.invoke(ZAPDriver.java:2523) at hudson.FilePath.act(FilePath.java:996) at hudson.FilePath.act(FilePath.java:974) at org.jenkinsci.plugins.zap.ZAPDriver.startZAP(ZAPDriver.java:641) at org.jenkinsci.plugins.zap.ZAPBuilder.perform(ZAPBuilder.java:281) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779) at hudson.model.Build$BuildExecution.build(Build.java:205) at hudson.model.Build$BuildExecution.doRun(Build.java:162) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:534) at hudson.model.Run.execute(Run.java:1728) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:404) ERROR: Unable to connect to ZAP's proxy after 60 seconds. at org.jenkinsci.plugins.zap.ZAPDriver.waitForSuccessfulConnectionToZap(ZAPDriver.java:749) at org.jenkinsci.plugins.zap.ZAPDriver.access$100(ZAPDriver.java:104) at org.jenkinsci.plugins.zap.ZAPDriver$WaitZAPDriverInitCallable.invoke(ZAPDriver.java:2537) at org.jenkinsci.plugins.zap.ZAPDriver$WaitZAPDriverInitCallable.invoke(ZAPDriver.java:2523) at hudson.FilePath.act(FilePath.java:996) at hudson.FilePath.act(FilePath.java:974) at org.jenkinsci.plugins.zap.ZAPDriver.startZAP(ZAPDriver.java:641) at org.jenkinsci.plugins.zap.ZAPBuilder.perform(ZAPBuilder.java:281) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779) at hudson.model.Build$BuildExecution.build(Build.java:205) at hudson.model.Build$BuildExecution.doRun(Build.java:162) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:534) at hudson.model.Run.execute(Run.java:1728) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:404) Build step 'Execute ZAP' marked build as failure Started calculate disk usage of build Finished Calculation of disk usage of build in 0 seconds Started calculate disk usage of workspace Finished Calculation of disk usage of workspace in 0 seconds Finished: FAILURE
--
You received this message because you are subscribed to the Google Groups "ZAP Jenkins Plugin" group.
To unsubscribe from this group and stop receiving emails from it, send an email to zaproxy-jenki...@googlegroups.com.
To post to this group, send email to zaproxy...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/zaproxy-jenkins/26e9f2f0-cbe5-4d2c-bf4f-219c277fd92e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Failed to create directory /root/.ZAP Unable to initialize home directory! /root/.ZAP/log4j.properties (Permission denied) java.io.FileNotFoundException: /root/.ZAP/log4j.properties (Permission denied)
$ZAPROXY_HOME/zap.sh -daemon -host 127.0.0.1 -port 8055 -config api.key=ZAPROXY-PLUGIN -dir /root/.ZAP -installdir $ZAPROXY_HOMEAs for the permissions and file ownership, I entirely set both of the zap directories under the ownership of jenkins, just to make sure that jenkins doesn't cause any silly issues and has full rights.
So yeah, that's my current situation at the moment. Looking forward to hearing from you :)
Thanks!