Skip to content
Snippets Groups Projects
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
pom.xml 6.44 KiB
<?xml version="1.0" encoding="UTF-8"?>
<!--

Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.​
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

     http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<project xmlns="http://maven.apache.org/POM/4.0.0"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>org.example</groupId>
    <artifactId>notification-push-endpoint</artifactId>
    <packaging>jar</packaging>
    <version>1.0-SNAPSHOT</version>

    <parent>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-parent</artifactId>
        <version>3.1.4</version>
        <relativePath/>
    </parent>

    <properties>
        <maven.compiler.source>17</maven.compiler.source>
        <maven.compiler.target>17</maven.compiler.target>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <os-core-common.version>0.23.0-SNAPSHOT</os-core-common.version>
        <spring-boot-maven-plugin.version>2.7.6</spring-boot-maven-plugin.version>
        <aws-java-sdk.version>1.11.1018</aws-java-sdk.version>
        <aws-encryption-sdk-java.version>2.4.0</aws-encryption-sdk-java.version>
    </properties>

    <dependencies>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-security</artifactId>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-web</artifactId>
        </dependency>
        <dependency>
            <groupId>org.opengroup.osdu</groupId>
            <artifactId>os-core-common</artifactId>
            <version>${os-core-common.version}</version>
        </dependency>
        <dependency>
            <groupId>com.amazonaws</groupId>
            <artifactId>aws-encryption-sdk-java</artifactId>
            <version>${aws-encryption-sdk-java.version}</version>
        </dependency>
        <dependency>
            <groupId>com.amazonaws</groupId>
            <artifactId>aws-java-sdk-sqs</artifactId>
            <version>${aws-java-sdk.version}</version>
        </dependency>
        <dependency>
            <groupId>com.amazonaws</groupId>
            <artifactId>aws-java-sdk-sts</artifactId>
            <version>${aws-java-sdk.version}</version>
        </dependency>
    </dependencies>

    <profiles>
      <profile>
            <id>aws-dev</id>
            <activation>
                <property>
                    <name>deployment.environment</name>
                    <value>dev</value>
                </property>
            </activation>
            <properties>
                <aws.version>1.11.1018</aws.version>
                <repo.releases.id>community-maven-repo</repo.releases.id>
                <publish.snapshots.id>community-maven-via-job-token</publish.snapshots.id>
                <publish.releases.id>community-maven-via-job-token</publish.releases.id>
                <repo.releases.url>https://community.opengroup.org/api/v4/groups/17/-/packages/maven</repo.releases.url>
                <publish.snapshots.url>https://community.opengroup.org/api/v4/projects/143/packages/maven</publish.snapshots.url>
                <publish.releases.url>https://community.opengroup.org/api/v4/projects/143/packages/maven</publish.releases.url>
            </properties>
        </profile>
    </profiles>

    <repositories>
        <repository>
            <id>${repo.releases.id}</id>
            <url>${repo.releases.url}</url>
        </repository>
    </repositories>

    <distributionManagement>
        <repository>
            <id>${publish.releases.id}</id>
            <url>${publish.releases.url}</url>
        </repository>
        <snapshotRepository>
            <id>${publish.snapshots.id}</id>
            <url>${publish.snapshots.url}</url>
        </snapshotRepository>
    </distributionManagement>

    <build>
        <plugins>
            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
                <version>${spring-boot-maven-plugin.version}</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>repackage</goal>
                        </goals>
                        <configuration>
                            <classifier>spring-boot</classifier>
                            <mainClass>
                                org.example.Application
                            </mainClass>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-shade-plugin</artifactId>
                <version>3.5.1</version>
                <configuration>
                    <createDependencyReducedPom>false</createDependencyReducedPom>
                </configuration>
                <executions>
                    <execution>
                        <phase>package</phase>
                        <goals>
                            <goal>shade</goal>
                        </goals>
                        <configuration>
                            <filters>
                                <filter>
                                    <artifact>*:*</artifact>
                                    <excludes>
                                        <exclude>META-INF/*.SF</exclude>
                                        <exclude>META-INF/*.DSA</exclude>
                                        <exclude>META-INF/*.RSA</exclude>
                                    </excludes>
                                </filter>
                            </filters>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

</project>