rpm-maven-plugin icon indicating copy to clipboard operation
rpm-maven-plugin copied to clipboard

Two soft links under one mapping not work as expected

Open 94d90b08-c4ef-416c-bf7b-b6c5b7275e6a opened this issue 7 years ago • 0 comments

Version: 2.1 Case: add two symbolic links in one mapping like this

<mapping>
  <directory>/var/lib/${project.artifactId}</directory>
  <sources>
    <source>
      <location>target/some_source_dir</location>
    </source>
    <softlinkSource>
      <location>/var/log/${project.artifactId}</location>
      <destination>logs</destination>
    </softlinkSource>
    <softlinkSource>
      <location>/etc/${project.artifactId}</location>
      <destination>conf</destination>
    </softlinkSource>
  </sources>
</mapping>

And one linked directory contain files (e.g. /etc/${project.artifactId}) than other one not. Result: Every file under /etc/${project.artifactId} links undo /var/lib/${project.artifactId} instead whole directory /var/log/${project.artifactId} source ignored at all Any single soft link works fine Expected: two links under /var/lib/${project.artifactId} - logs and conf Workaround: use separated mapping for each soft link:

<mapping>
    <directory>/var/lib/${project.artifactId}/logs</directory>
    <sources>
        <softlinkSource>
          <location>/var/log/${project.artifactId}</location>
        </softlinkSource>
    </sources>
</mapping>