sbt / sbt-native-packager

sbt Native Packager
https://sbt-native-packager.readthedocs.io/en/stable/
BSD 2-Clause "Simplified" License
1.6k stars 441 forks source link

docker:publishLocal do not use "sbt.ivy.home" #639

Open yanns opened 9 years ago

yanns commented 9 years ago

Hi,

running docker:publishLocal works locally.

On TeamCity, where sbt is started with -Dsbt.ivy.home=/TeamCityAgent/system/sbt_ivy, we have the following error:

[12:31:34][Step 1/2] java.io.FileNotFoundException: /root/.ivy2/local/de.commercetools/sphere_2.11/0.1-SNAPSHOT/poms/sphere_2.11.pom (No such file or directory)
[12:31:34][Step 1/2]    at java.io.FileOutputStream.open0(Native Method)
[12:31:34][Step 1/2]    at java.io.FileOutputStream.open(FileOutputStream.java:270)
[12:31:34][Step 1/2]    at java.io.FileOutputStream.<init>(FileOutputStream.java:213)
[12:31:34][Step 1/2]    at java.io.FileOutputStream.<init>(FileOutputStream.java:162)
[12:31:34][Step 1/2]    at org.apache.ivy.util.FileUtil.copy(FileUtil.java:157)
[12:31:34][Step 1/2]    at org.apache.ivy.util.FileUtil.copy(FileUtil.java:132)
[12:31:34][Step 1/2]    at org.apache.ivy.plugins.repository.file.FileRepository.copy(FileRepository.java:76)
[12:31:34][Step 1/2]    at org.apache.ivy.plugins.repository.file.FileRepository.put(FileRepository.java:58)
[12:31:34][Step 1/2]    at sbt.ConvertResolver$WarnOnOverwriteFileRepo.put(ConvertResolver.scala:273)
[12:31:34][Step 1/2]    at org.apache.ivy.plugins.repository.AbstractRepository.put(AbstractRepository.java:130)
[12:31:34][Step 1/2]    at org.apache.ivy.plugins.resolver.RepositoryResolver.put(RepositoryResolver.java:234)
[12:31:34][Step 1/2]    at org.apache.ivy.plugins.resolver.RepositoryResolver.publish(RepositoryResolver.java:216)
[12:31:34][Step 1/2]    at sbt.IvyActions$$anonfun$publish$3.apply(IvyActions.scala:336)
[12:31:34][Step 1/2]    at sbt.IvyActions$$anonfun$publish$3.apply(IvyActions.scala:335)
[12:31:34][Step 1/2]    at scala.collection.TraversableLike$WithFilter$$anonfun$foreach$1.apply(TraversableLike.scala:772)
[12:31:34][Step 1/2]    at scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:59)
[12:31:34][Step 1/2]    at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:47)
[12:31:34][Step 1/2]    at scala.collection.TraversableLike$WithFilter.foreach(TraversableLike.scala:771)
[12:31:34][Step 1/2]    at sbt.IvyActions$.publish(IvyActions.scala:335)
[12:31:34][Step 1/2]    at sbt.IvyActions$$anonfun$publish$1$$anonfun$apply$1.apply$mcV$sp(IvyActions.scala:121)
[12:31:34][Step 1/2]    at sbt.IvyActions$$anonfun$publish$1$$anonfun$apply$1.apply(IvyActions.scala:121)
[12:31:34][Step 1/2]    at sbt.IvyActions$$anonfun$publish$1$$anonfun$apply$1.apply(IvyActions.scala:121)
[12:31:34][Step 1/2]    at sbt.IvyActions$.withChecksums(IvyActions.scala:130)
[12:31:34][Step 1/2]    at sbt.IvyActions$.sbt$IvyActions$$withChecksums(IvyActions.scala:125)
[12:31:34][Step 1/2]    at sbt.IvyActions$$anonfun$publish$1.apply(IvyActions.scala:121)
[12:31:34][Step 1/2]    at sbt.IvyActions$$anonfun$publish$1.apply(IvyActions.scala:114)
[12:31:34][Step 1/2]    at sbt.IvySbt$Module$$anonfun$withModule$1.apply(Ivy.scala:155)
[12:31:34][Step 1/2]    at sbt.IvySbt$Module$$anonfun$withModule$1.apply(Ivy.scala:155)
[12:31:34][Step 1/2]    at sbt.IvySbt$$anonfun$withIvy$1.apply(Ivy.scala:132)
[12:31:34][Step 1/2]    at sbt.IvySbt.sbt$IvySbt$$action$1(Ivy.scala:57)
[12:31:34][Step 1/2]    at sbt.IvySbt$$anon$4.call(Ivy.scala:65)
[12:31:34][Step 1/2]    at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:93)
[12:31:34][Step 1/2]    at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:78)
[12:31:34][Step 1/2]    at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:97)
[12:31:34][Step 1/2]    at xsbt.boot.Using$.withResource(Using.scala:10)
[12:31:34][Step 1/2]    at xsbt.boot.Using$.apply(Using.scala:9)
[12:31:34][Step 1/2]    at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:58)
[12:31:34][Step 1/2]    at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:48)
[12:31:34][Step 1/2]    at xsbt.boot.Locks$.apply0(Locks.scala:31)
[12:31:34][Step 1/2]    at xsbt.boot.Locks$.apply(Locks.scala:28)
[12:31:34][Step 1/2]    at sbt.IvySbt.withDefaultLogger(Ivy.scala:65)
[12:31:34][Step 1/2]    at sbt.IvySbt.withIvy(Ivy.scala:127)
[12:31:34][Step 1/2]    at sbt.IvySbt.withIvy(Ivy.scala:124)
[12:31:34][Step 1/2]    at sbt.IvySbt$Module.withModule(Ivy.scala:155)
[12:31:34][Step 1/2]    at sbt.IvyActions$.publish(IvyActions.scala:114)
[12:31:34][Step 1/2]    at sbt.Classpaths$$anonfun$publishTask$1.apply(Defaults.scala:1283)
[12:31:34][Step 1/2]    at sbt.Classpaths$$anonfun$publishTask$1.apply(Defaults.scala:1282)
[12:31:34][Step 1/2]    at scala.Function3$$anonfun$tupled$1.apply(Function3.scala:35)
[12:31:34][Step 1/2]    at scala.Function3$$anonfun$tupled$1.apply(Function3.scala:34)
[12:31:34][Step 1/2]    at scala.Function1$$anonfun$compose$1.apply(Function1.scala:47)
[12:31:34][Step 1/2]    at sbt.$tilde$greater$$anonfun$$u2219$1.apply(TypeFunctions.scala:40)
[12:31:34][Step 1/2]    at sbt.std.Transform$$anon$4.work(System.scala:63)
[12:31:34][Step 1/2]    at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:226)
[12:31:34][Step 1/2]    at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:226)
[12:31:34][Step 1/2]    at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:17)
[12:31:34][Step 1/2]    at sbt.Execute.work(Execute.scala:235)
[12:31:34][Step 1/2]    at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:226)
[12:31:34][Step 1/2]    at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:226)
[12:31:34][Step 1/2]    at sbt.ConcurrentRestrictions$$anon$4$$anonfun$1.apply(ConcurrentRestrictions.scala:159)
[12:31:34][Step 1/2]    at sbt.CompletionService$$anon$2.call(CompletionService.scala:28)
[12:31:34][Step 1/2]    at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[12:31:34][Step 1/2]    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[12:31:34][Step 1/2]    at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[12:31:34][Step 1/2]    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
[12:31:34][Step 1/2]    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
[12:31:34][Step 1/2]    at java.lang.Thread.run(Thread.java:745)
muuki88 commented 9 years ago

Hm. This doesn't sound like a native-packager problem. Can you cross post this on the sbt issues and link it here?

cc @jsuereth