<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/maven-v4_0_0.xsd">
   <modelVersion>4.0.0</modelVersion>
   <artifactId>content-services-community-docker-ags</artifactId>
   <name>Alfresco Content Services Community Docker Image Builder for AGS</name>
   <description>Alfresco Governance Services Community Repository Extension</description>
   <packaging>pom</packaging>

   <parent>
      <groupId>org.alfresco</groupId>
      <artifactId>content-services-community-docker</artifactId>
      <version>23.1.0-A17</version>
   </parent>

   <properties>
      <image.name>alfresco/alfresco-governance-repository-community</image.name>
      <base.image>alfresco/alfresco-content-repository-community:${image.tag}</base.image>
      <scripts.directory>${project.parent.parent.basedir}/scripts/dev</scripts.directory>
   </properties>

   <build>
      <plugins>
         <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-dependency-plugin</artifactId>
            <executions>
               <execution>
                  <id>unpack-war-files</id>
                  <phase>process-resources</phase>
                  <goals>
                     <goal>unpack</goal>
                  </goals>
                  <configuration>
                     <artifactItems>
                        <artifactItem>
                           <groupId>org.alfresco</groupId>
                           <artifactId>api-explorer</artifactId>
                           <version>${alfresco.api-explorer.version}</version>
                           <type>war</type>
                           <outputDirectory>${project.build.directory}/war/api-explorer</outputDirectory>
                        </artifactItem>
                     </artifactItems>
                  </configuration>
               </execution>
               <execution>
                  <id>copy-amps</id>
                  <phase>process-resources</phase>
                  <goals>
                     <goal>copy</goal>
                  </goals>
                  <configuration>
                     <artifactItems>
                        <artifactItem>
                           <groupId>org.alfresco</groupId>
                           <artifactId>alfresco-governance-services-community-rest-api-explorer</artifactId>
                           <version>${dependency.alfresco-community-repo.version}</version>
                           <type>war</type>
                           <destFileName>gs-api-explorer-${dependency.alfresco-community-repo.version}.war</destFileName>
                           <outputDirectory>${project.build.directory}</outputDirectory>
                        </artifactItem>
                        <artifactItem>
                           <groupId>org.alfresco</groupId>
                           <artifactId>alfresco-governance-services-community-repo</artifactId>
                           <version>${dependency.alfresco-community-repo.version}</version>
                           <type>amp</type>
                           <outputDirectory>${project.build.directory}</outputDirectory>
                        </artifactItem>
                     </artifactItems>
                  </configuration>
               </execution>
            </executions>
         </plugin>
      </plugins>
   </build>
</project>