Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1.9.0 jar cannot be launched #51

Open
neilyoung opened this issue Feb 28, 2024 · 2 comments
Open

1.9.0 jar cannot be launched #51

neilyoung opened this issue Feb 28, 2024 · 2 comments

Comments

@neilyoung
Copy link

Seems to be missing main class entry in Manifest:

ubuntu@ca:~/backend$ java -jar /home/ubuntu/backend/sample/target/sample-1.9.0.jar
no main manifest attribute, in /home/ubuntu/backend/sample/target/sample-1.9.0.jar
@neilyoung
Copy link
Author

Manifest of the current target:

image

Compared to manifest of the 1.8.0 target:

image

@neilyoung
Copy link
Author

Found it. This section is missing from sample/src/pom.xml:

<build>
        <plugins>
            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
                <version>1.1.12.RELEASE</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>repackage</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant