一尘不染

具有不同行为的同一个行家

jenkins

我试图用来Vagrant创建我的new virtual machineJenkins以确保我的构建/项目的质量。该项目也需要使用RPostgres。一切在我的本地计算机上都可以正常运行,但是现在我正在尝试使环境一致,可重现。当我尝试mvn clean package在新的虚拟机中运行时,maven会中断一个test在本机中正常运行但 不在 新vm中运行的。

我检查了版本JavaMavenPostgresR(其packages)一切都是一样的。但是,我的Maven项目在此测试中失败了。

我在这里想念什么?任何想法,建议都会受到赞赏,因为我现在还没有想法,到目前为止,我已经尝试了所有方法。(在此问题上超过12个小时。)

编辑

Java-主机

valter@eniac:document-engine$ java -version
java version "1.8.0_66"
Java(TM) SE Runtime Environment (build 1.8.0_66-b17)
Java HotSpot(TM) 64-Bit Server VM (build 25.66-b17, mixed mode)

Java-虚拟机

vagrant@vagrant-ubuntu-trusty-64:~/$ java -version
java version "1.8.0_65"
Java(TM) SE Runtime Environment (build 1.8.0_65-b17)
Java HotSpot(TM) 64-Bit Server VM (build 25.65-b01, mixed mode)

Maven-主机

valter@eniac:document-engine$ mvn -version
Apache Maven 3.0.5
Maven home: /usr/share/maven
Java version: 1.8.0_66, vendor: Oracle Corporation
Java home: /usr/lib/jvm/java-8-oracle/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "3.19.0-31-generic", arch: "amd64", family: "unix"

Maven-虚拟机

vagrant@vagrant-ubuntu-trusty-64:~$ mvn -version
Apache Maven 3.0.5
Maven home: /usr/share/maven
Java version: 1.8.0_65, vendor: Oracle Corporation
Java home: /opt/jdk/jdk1.8.0_65/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "3.13.0-66-generic", arch: "amd64", family: "unix"
vagrant@vagrant-ubuntu-trusty-64:~$

PostgreSQL-主机

valter@eniac:document-engine$ psql --version
psql (PostgreSQL) 9.3.10

PostgreSQL-虚拟机

vagrant@vagrant-ubuntu-trusty-64:~$ psql --version
psql (PostgreSQL) 9.3.10

R-主机

> sessionInfo()
R version 3.2.2 (2015-08-14)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 14.04.3 LTS

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
 [3] LC_TIME=de_DE.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=de_DE.UTF-8    LC_MESSAGES=en_US.UTF-8   
 [7] LC_PAPER=de_DE.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=de_DE.UTF-8 LC_IDENTIFICATION=C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

other attached packages:
 [1] PerformanceAnalytics_1.4.3541 xts_0.9-7                    
 [3] zoo_1.7-12                    HiddenMarkov_1.8-4           
 [5] gplots_2.17.0                 gmodels_2.16.2               
 [7] gtools_3.5.0                  lattice_0.20-33              
 [9] MASS_7.3-44                   tseries_0.10-34              
[11] fGarch_3010.82                fBasics_3011.87              
[13] timeSeries_3012.99            timeDate_3012.100            
[15] Rserve_1.7-3

loaded via a namespace (and not attached):
[1] quadprog_1.5-5     bitops_1.0-6       grid_3.2.2         KernSmooth_2.23-15
[5] gdata_2.17.0       caTools_1.17.1

R-虚拟机

> sessionInfo()
R version 3.2.2 (2015-08-14)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 14.04.3 LTS

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
 [3] LC_TIME=de_DE.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=de_DE.UTF-8    LC_MESSAGES=en_US.UTF-8   
 [7] LC_PAPER=de_DE.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=de_DE.UTF-8 LC_IDENTIFICATION=C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

other attached packages:
 [1] PerformanceAnalytics_1.4.3541 xts_0.9-7                    
 [3] zoo_1.7-12                    HiddenMarkov_1.8-4           
 [5] gplots_2.17.0                 gmodels_2.16.2               
 [7] gtools_3.5.0                  lattice_0.20-33              
 [9] MASS_7.3-44                   tseries_0.10-34              
[11] fGarch_3010.82                fBasics_3011.87              
[13] timeSeries_3012.99            timeDate_3012.100            
[15] Rserve_1.7-3

loaded via a namespace (and not attached):
[1] quadprog_1.5-5     bitops_1.0-6       grid_3.2.2         KernSmooth_2.23-15
[5] gdata_2.17.0       caTools_1.17.1

阅读 292

收藏
2020-07-25

共1个答案

一尘不染

只是为了让您知道我的问题发生了什么。问题是 TIMEZONE 。我不知道为什么,但是R或者我们用于计算的某些程序包要求时区相同。

我位于德国(时区CET为+1
UTC
),并且我将我的虚拟机设置为使用UTC,因此出现了问题。噢,伙计,我真的很高兴解决这个问题(为此连续工作了三天!),但是现在一切都很好!非常感谢我的同事给我@Ralf小费!

2020-07-25