Spring Cloud Skipper Maven plugin
This plugin adds the ability to create a Skipper package as part of the Maven build process.
It contains templates
for the common package files and uses the Maven project values to populate much of the template properties
project.version, etc.). It also provides the ability to override any of these template
files in the project if you need to tweak or add properties.
See this blog post for more context:
Default Skipper package templates
The default templates are located at
src/main/resources/skipper $ tree ├── package.yml ├── templates │ └── template.yml └── values.yml
The Spring Cloud Skipper Maven Plugin has the following goals.
- skipper-package creates a Spring Cloud Skipper compliant package
- skipper-upload uploads Spring Cloud Skipper package to a Skipper repository
<build> <plugins> ... <plugin> <groupId>io.switchbit</groupId> <artifactId>spring-cloud-skipper-maven-plugin</artifactId> <version>0.1.0.BUILD-SNAPSHOT</version> <executions> <execution> <phase>package</phase> <goals> <goal>skipper-package</goal> </goals> </execution> </executions> </plugin> ... </plugins> </build>
Creating a Skipper package
The configuration above will create the Skipper package on the
In short it will copy the template package files into your build directory, overwrite any templates
in the current project, allowing you to override templates when you need too and then filter
the templates, replacing the respective values with their project POM values. Once that's done it zip's them all
up into a Skipper package.
Deploying the Skipper package
This uploads the Skipper package built with the
skipper-package goal to the repository specified (default:
See the below attributes to customise which Skipper server to target etc.
- Requires a Maven project to be executed.
- Binds by default to the lifecycle phase:
||The directory where template files that will override the default tempaltes are located.||
||The directory where the template files will be copied too during packaging||
||The URI of the Skipper server to target||
||The repository to upload the Skipper package too||
The Fabric8 Maven plugin was a great reference when creating this plugin. Specifically how to load and process resources.