-
Notifications
You must be signed in to change notification settings - Fork 3
/
pom.xml
190 lines (185 loc) · 7.81 KB
/
pom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
<?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>${groupId}</groupId>
<artifactId>${artifactId}</artifactId>
<version>${version}</version>
<packaging>jar</packaging>
<properties>
<kotlin.version>1.1.4-3</kotlin.version>
<osiris.version>${osirisVersion}</osiris.version>
<jackson.version>2.8.7</jackson.version>
<logback.version>1.2.3</logback.version>
</properties>
<dependencies>
<dependency>
<groupId>io.github.cjkent.osiris</groupId>
<artifactId>osiris-core</artifactId>
<version>${osiris.version}</version>
</dependency>
<dependency>
<groupId>io.github.cjkent.osiris</groupId>
<artifactId>osiris-local-server</artifactId>
<version>${osiris.version}</version>
</dependency>
<dependency>
<groupId>io.github.cjkent.osiris</groupId>
<artifactId>osiris-aws</artifactId>
<version>${osiris.version}</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-stdlib-jre8</artifactId>
<version>${kotlin.version}</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>${jackson.version}</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.module</groupId>
<artifactId>jackson-module-kotlin</artifactId>
<version>${jackson.version}</version>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
<version>${logback.version}</version>
</dependency>
</dependencies>
<build>
<sourceDirectory>src/main/kotlin</sourceDirectory>
<testSourceDirectory>src/test/kotlin</testSourceDirectory>
<plugins>
<!--Configuration controlling how the API is deployed to API Gateway and Lambda-->
<plugin>
<groupId>io.github.cjkent.osiris</groupId>
<artifactId>osiris-maven-plugin</artifactId>
<version>${osiris.version}</version>
<configuration>
<apiName>${artifactId}</apiName>
<region>eu-west-1</region>
<apiDefinitionClass>${package}.ExampleApiDefinition</apiDefinitionClass>
<componentsClass>${package}.ExampleComponentsImpl</componentsClass>
<stages>
<dev>
<deployOnUpdate>true</deployOnUpdate>
<description>Development stage</description>
<variables>
<var1>devValue1</var1>
<var2>devValue2</var2>
</variables>
</dev>
<!-- Stage with no variables or description that is not deployed when it is updated -->
<uat/>
<prod>
<deployOnUpdate>false</deployOnUpdate>
<description>Production stage</description>
<variables>
<var1>prodValue1</var1>
<var2>prodValue2</var2>
</variables>
</prod>
</stages>
<environmentVariables>
<EXAMPLE_ENVIRONMENT_VARIABLE>Bob</EXAMPLE_ENVIRONMENT_VARIABLE>
</environmentVariables>
</configuration>
<executions>
<execution>
<goals>
<goal>deploy</goal>
</goals>
</execution>
</executions>
</plugin>
<!--Configuration controlling how the API is run locally using 'mvn exec:exec'-->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>1.5.0</version>
<executions>
<execution>
<goals>
<goal>exec</goal>
</goals>
</execution>
</executions>
<configuration>
<executable>java</executable>
<arguments>
<argument>-classpath</argument>
<classpath/>
<argument>io.github.cjkent.osiris.localserver.LocalServerKt</argument>
<argument>-p</argument>
<argument>8080</argument>
<argument>-d</argument>
<argument>${package}.ExampleApiDefinition</argument>
<argument>-c</argument>
<argument>${package}.ExampleComponentsImpl</argument>
</arguments>
<environmentVariables>
<EXAMPLE_ENVIRONMENT_VARIABLE>Bob</EXAMPLE_ENVIRONMENT_VARIABLE>
</environmentVariables>
</configuration>
</plugin>
<!--Standard plugins - this configuration shouldn't need to be changed-->
<plugin>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-maven-plugin</artifactId>
<version>${kotlin.version}</version>
<executions>
<execution>
<id>compile</id>
<phase>compile</phase>
<goals>
<goal>compile</goal>
</goals>
</execution>
<execution>
<id>test-compile</id>
<phase>test-compile</phase>
<goals>
<goal>test-compile</goal>
</goals>
</execution>
</executions>
<configuration>
<jvmTarget>1.8</jvmTarget>
</configuration>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>3.0.0</version>
<configuration>
<descriptors>
<descriptor>${project.basedir}/src/assembly/jar-with-dependencies.xml</descriptor>
</descriptors>
</configuration>
<executions>
<execution>
<id>make-assembly</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
<pluginManagement>
<plugins>
<!--Disable the standard deployment plugin because we don't want to use it-->
<plugin>
<artifactId>maven-deploy-plugin</artifactId>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
</project>