Skip to content

Cannot run repackage twice with different settings #15034

@wouterv

Description

@wouterv

Since the release of 2.1.0.RELEASE, we get the following issue in our build:

build	31-Oct-2018 15:08:38	[ERROR] Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:2.1.0.RELEASE:repackage (build-repackaged-jar) on project application: Execution build-repackaged-jar of goal org.springframework.boot:spring-boot-maven-plugin:2.1.0.RELEASE:repackage failed: Source must refer to an existing file, got /atlassian/bamboo/agent/5.15.3/xml-data/build-dir/BC-BGS-JOB1/repo/application/target/gear-exec-linux.jar.original -> [Help 1]

We fixed the plugin version to 2.0.6.RELEASE and all works fine again.

This is our specific part in the pom, the special thing about is that it creates two artifacts:

 <plugin>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-maven-plugin</artifactId>
    <version>2.0.6.RELEASE</version> <!-- remove this and it will fail -->
    <executions>
        <execution>
            <id>build-linux-executable</id>
            <goals>
                <goal>repackage</goal>
            </goals>
            <configuration>
                <classifier>exec-linux</classifier>
                <executable>true</executable>
                <attach>false</attach>
            </configuration>
        </execution>    
        <execution>
            <id>build-repackaged-jar</id>
            <goals>
                <goal>repackage</goal>
            </goals>
            <configuration>
                <executable>false</executable>
                <attach>true</attach>
            </configuration>
        </execution>
    </executions>
</plugin>

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions