<?xml version="1.0" encoding="UTF-8"?>

<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>karaf-maven-plugin-test</artifactId>
    <version>1.0.0-SNAPSHOT</version>
    <packaging>pom</packaging>
  
    <properties>
        <karaf.version>4.0.6-SNAPSHOT</karaf.version>
        <camel.version>2.17.3</camel.version>
    </properties>


    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.karaf.tooling</groupId>
                <artifactId>karaf-maven-plugin</artifactId>
                <version>${karaf.version}</version>
                <executions>
                    <execution>
                        <id>add-features-to-repo</id>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>features-add-to-repository</goal>
                        </goals>
                        <configuration>
                            <descriptors>
                                <descriptor>mvn:org.apache.camel.karaf/apache-camel/${camel.version}/xml/features</descriptor>
                            </descriptors>
                            <features>
                                <feature>camel-restlet</feature>
                            </features>
                            <repository>target/features-repo</repository>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <repositories>
        <repository>
            <id>apache-snapshots</id>
            <url>http://repository.apache.org/snapshots</url>
            <name>Apache Snapshots Repo</name>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
            <releases>
                <enabled>false</enabled>
            </releases>
        </repository>
    </repositories>
    <pluginRepositories>
        <pluginRepository>
            <id>apache-snapshots</id>
            <url>http://repository.apache.org/snapshots</url>
            <name>Apache Snapshots Repo</name>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
            <releases>
                <enabled>false</enabled>
            </releases>
        </pluginRepository>
    </pluginRepositories>

</project>