jdeb
jdeb copied to clipboard
data/type file broken
Used to work on 1.5 with 1.8 only the dst directory part is created
<data>
<src>${project.build.directory}/${project.artifactId}.service</src>
<type>file</type>
<dst>/etc/systemd/system/${project.artifactId}.service</dst>
<mapper>
<type>perm</type>
<filemode>755</filemode>
</mapper>
</data>
As a workaround using the type directory with includes works for the same
<data>
<src>${project.build.directory}</src>
<includes>${project.artifactId}.service</includes>
<type>directory</type>
<mapper>
<prefix>/etc/systemd/system</prefix>
<type>perm</type>
<filemode>755</filemode>
</mapper>
</data>
@TuireHolappa can please provide a few more details?
IIUC only /etc/systemd/system/ gets created? instead of /etc/systemd/system/${project.artifactId}.service?
Do you have the project available somewhere?
Hi, this is unfortunately a company project with some parent poms involved so I cannot share this one. I'll try to find some time to compose a simple example for you next week.
It was not too complexed to reproduce similar situation on .deb content. 312example.zip I hope this helps to find the cause. I do like to have your plugin for .deb creation. And the env that I used is windows but our Jenkins runs on Linux node and the outcome was the same.
@TuireHolappa thanks for the test case. Looking at the deb I am not sure I see the problem yet.
This is what the deb looks for me like:
./usr
./usr/local
./usr/local/example
./usr/local/example/jdeb-file-example
./usr/local/example/jdeb-file-example/jdeb-file-example-0.0.1-SNAPSHOT.jar
./usr/share
./usr/share/doc
./usr/share/doc/jdeb-file-example
./usr/share/doc/jdeb-file-example/changelog
./usr/share/doc/jdeb-file-example/copyright
./etc
./etc/systemd
./etc/systemd/system
./etc/systemd/system/jdeb-file-example.service
If yours looks different, please attach the deb.
The jdeb-file-example_0.0.1~SNAPSHOT_all.deb is inside the zip already. Please check 321example.zip/jedb-file-example/target
And note that our legacy system uses still java 8 also as build environment.
@TuireHolappa Ah, sorry - I didn't realize. But then yours looks the same - and to my account OK:
% find .
.
./usr
./usr/local
./usr/local/example
./usr/local/example/jdeb-file-example
./usr/local/example/jdeb-file-example/jdeb-file-example-0.0.1-SNAPSHOT.jar
./usr/share
./usr/share/doc
./usr/share/doc/jdeb-file-example
./usr/share/doc/jdeb-file-example/changelog
./usr/share/doc/jdeb-file-example/copyright
./etc
./etc/systemd
./etc/systemd/system
./etc/systemd/system/jdeb-file-example.service
Yep you are correct. It is there and visible when I extract the contents to disk. Did not try that out when checked the content. Strange is that it is invisible when browsing with 7 zip. When the file is added with the directory shows that and also if I package with the file with 1.5 it is visible. So something is different.
Well, that should at least make it very easy to find the difference. Next step would be to compare the meta data details of both archives.