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

    Copyright (C) 2015 Red Hat, Inc.

    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/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>io.fabric8</groupId>
    <artifactId>kubernetes-model-generator</artifactId>
    <version>7.9.0</version>
  </parent>

  <artifactId>kubernetes-model-batch</artifactId>
  <packaging>bundle</packaging>
  <name>Fabric8 :: Kubernetes Model :: Batch</name>

  <properties>
    <clone-kube>true</clone-kube>
    <osgi.import>*</osgi.import>
    <osgi.export>
      io.fabric8.kubernetes.api.model.batch**
    </osgi.export>
  </properties>

  <dependencies>
    <dependency>
      <groupId>io.fabric8</groupId>
      <artifactId>kubernetes-model-core</artifactId>
    </dependency>
    <dependency>
      <groupId>io.fabric8</groupId>
      <artifactId>kubernetes-model-scheduling</artifactId>
    </dependency>
  </dependencies>

  <!-- The build config that snapshots/compiles the committed sundrio Builders is generic and lives
       in the parent pom (kubernetes-model-generator): its unconditional <build> for the default build,
       plus the 'generate' profile for regeneration. -->
  <profiles>
    <profile>
      <id>generate</id>
      <build>
        <plugins>
          <plugin>
            <groupId>io.fabric8</groupId>
            <artifactId>openapi-model-generator-maven-plugin</artifactId>
            <configuration >
              <settings combine.self="append">
                <schemas>
                  <schema>${project.basedir}/../openapi/schemas/kubernetes-1.21.14.json</schema>
                  <schema>${openapi.schema.kubernetes-latest}</schema>
                </schemas>
                <packageMappings combine.self="append">
                  <io.k8s.api.batch>io.fabric8.kubernetes.api.model.batch</io.k8s.api.batch>
                </packageMappings>
                <includeGenerationRegexes>
                  <includeGenerationRegex>^io\.k8s\.api\.batch\..*$</includeGenerationRegex>
                </includeGenerationRegexes>
              </settings>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
