Skip to content

Commit

Permalink
Use template when activating module
Browse files Browse the repository at this point in the history
  • Loading branch information
marcjohnson-kint committed Dec 20, 2017
1 parent 9536e41 commit 61d92fa
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 7 deletions.
3 changes: 3 additions & 0 deletions descriptors/Activate-template.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"id": "${artifactId}-${version}"
}
4 changes: 1 addition & 3 deletions okapi-registration/managed-deployment/register.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,7 @@ curl -w '\n' -D - -s \
-d @./target/ModuleDescriptor.json \
"${okapi_proxy_address}/_/proxy/modules"

activate_json=$(cat ./registration/activate.json)

curl -w '\n' -X POST -D - \
-H "Content-type: application/json" \
-d "${activate_json}" \
-d @./target/Activate.json \
"${okapi_proxy_address}/_/proxy/tenants/${tenant_id}/modules"
6 changes: 5 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@
<resources>
<resource>
<directory>${basedir}/descriptors</directory>
<include>*Descriptor*-template.json</include>
<include>*-template.json</include>
<filtering>true</filtering>
</resource>
</resources>
Expand Down Expand Up @@ -227,6 +227,10 @@
<sourceFile>${project.build.directory}/DeploymentDescriptor-environment-template.json</sourceFile>
<destinationFile>${project.build.directory}/DeploymentDescriptor-environment.json</destinationFile>
</fileSet>
<fileSet>
<sourceFile>${project.build.directory}/Activate-template.json</sourceFile>
<destinationFile>${project.build.directory}/Activate.json</destinationFile>
</fileSet>
</fileSets>
</configuration>
</execution>
Expand Down
3 changes: 0 additions & 3 deletions registration/activate.json

This file was deleted.

0 comments on commit 61d92fa

Please sign in to comment.