Skip to content

Commit

Permalink
Update Image names
Browse files Browse the repository at this point in the history
  • Loading branch information
enyachoke committed Aug 26, 2024
1 parent 705b599 commit 3416f76
Show file tree
Hide file tree
Showing 4 changed files with 237 additions and 221 deletions.
231 changes: 231 additions & 0 deletions maven-parent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -381,4 +381,235 @@

</plugins>
</build>
<profiles>
<profile>
<id>docker</id>
<properties>
<!-- Ozone Docker embedded version-->
<ozoneDockerEmbedded>1.0.0-SNAPSHOT</ozoneDockerEmbedded>
<!-- Docker image properties-->
<docker.tag>${project.groupId}-${project.artifactId}-${project.version}</docker.tag>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>Unpack Ozone Docker Embedded to a tempoarary location</id>
<phase>generate-resources</phase>
<goals>
<goal>unpack-dependencies</goal>
</goals>
<configuration>
<excludeTransitive>true</excludeTransitive>
<outputDirectory>${project.build.directory}/embedded-build-tmp/docker-embedded</outputDirectory>
<includeArtifactIds>ozone-docker-embedded</includeArtifactIds>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.gmavenplus</groupId>
<artifactId>gmavenplus-plugin</artifactId>
<executions>
<execution>
<id>Generate Docker Compose Embedded yaml</id>
<goals>
<goal>execute</goal>
</goals>
<phase>process-resources</phase>
<configuration>
<scripts>
<script>
file://${project.build.directory}/scripts/openmrs/docker-embedded/generate-docker-embedded-compose.groovy</script>
</scripts>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<executions>
<execution>
<!-- Copy Docker Embedded compose file to run directory -->
<id>Copy Docker Embedded compose file</id>
<phase>package</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<outputDirectory>
${project.build.directory}/${project.artifactId}-${project.version}/run/docker</outputDirectory>
<overwrite>true</overwrite>
<resources>
<resource>
<directory>
${project.build.directory}/embedded-build-tmp/docker-embedded</directory>
<filtering>true</filtering>
<includes>
<include>docker-compose-embedded.yaml</include>
</includes>
</resource>
</resources>
</configuration>
</execution>
<execution>
<!-- Copy Docker Embedded compose file to run directory -->
<id>Copy Ozone</id>
<phase>package</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<outputDirectory>
${project.build.directory}/embedded-build-tmp/distro</outputDirectory>
<overwrite>true</overwrite>
<resources>
<resource>
<directory>
${project.build.directory}/${project.artifactId}-${project.version}/distro</directory>
<filtering>false</filtering>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>io.fabric8</groupId>
<artifactId>docker-maven-plugin</artifactId>
<configuration>
<images>
<image>
<name>ozone-embedded-openmrs-backend:${docker.tag}</name>
<build>
<dockerFile>
${project.build.directory}/embedded-build-tmp/docker-embedded/openmrs/Dockerfile</dockerFile>
<contextDir>
${project.build.directory}/embedded-build-tmp/distro</contextDir>
</build>
</image>
<image>
<name>ozone-embedded-openmrs-frontend:${project.version}</name>
<build>
<dockerFile>
${project.build.directory}/embedded-build-tmp/docker-embedded/frontend/Dockerfile</dockerFile>
<contextDir>
${project.build.directory}/embedded-build-tmp/</contextDir>
</build>
</image>
<image>
<name>ozone-embedded-proxy:${docker.tag}</name>
<build>
<dockerFile>
${project.build.directory}/embedded-build-tmp/docker-embedded/proxy/Dockerfile</dockerFile>
<contextDir>
${project.build.directory}/embedded-build-tmp/</contextDir>
</build>
</image>
<image>
<name>ozone-embedded-odoo:${docker.tag}</name>
<build>
<dockerFile>
${project.build.directory}/embedded-build-tmp/docker-embedded/odoo/Dockerfile</dockerFile>
<contextDir>
${project.build.directory}/embedded-build-tmp/distro</contextDir>
</build>
</image>
<image>
<name>ozone-embedded-senaite:${docker.tag}</name>
<build>
<dockerFile>
${project.build.directory}/embedded-build-tmp/docker-embedded/senaite/Dockerfile</dockerFile>
<contextDir>
${project.build.directory}/embedded-build-tmp/distro</contextDir>
</build>
</image>
<image>
<name>ozone-embedded-erpnext:${docker.tag}</name>
<build>
<dockerFile>
${project.build.directory}/embedded-build-tmp/docker-embedded/erpnext/Dockerfile</dockerFile>
<contextDir>
${project.build.directory}/embedded-build-tmp/distro</contextDir>
</build>
</image>
<image>
<name>ozone-embedded-eip-erpnext-openmrs:${docker.tag}</name>
<build>
<dockerFile>
${project.build.directory}/embedded-build-tmp/docker-embedded/eip-erpnext-openmrs/Dockerfile</dockerFile>
<contextDir>
${project.build.directory}/embedded-build-tmp/distro</contextDir>
</build>
</image>
<image>
<name>ozone-embedded-eip-odoo-openmrs:${docker.tag}</name>
<build>
<dockerFile>
${project.build.directory}/embedded-build-tmp/docker-embedded/eip-odoo-openmrs/Dockerfile</dockerFile>
<contextDir>
${project.build.directory}/embedded-build-tmp/distro</contextDir>
</build>
</image>
<image>
<name>ozone-embedded-eip-openmrs-senaite:${docker.tag}</name>
<build>
<dockerFile>
${project.build.directory}/embedded-build-tmp/docker-embedded/eip-openmrs-senaite/Dockerfile</dockerFile>
<contextDir>
${project.build.directory}/embedded-build-tmp/distro</contextDir>
</build>
</image>
<image>
<name>ozone-embedded-postgresql:${project.version}</name>
<build>
<dockerFile>
${project.build.directory}/embedded-build-tmp/docker-embedded/postgresql/Dockerfile</dockerFile>
<contextDir>
${project.build.directory}/embedded-build-tmp/distro</contextDir>
</build>
</image>
<image>
<name>ozone-embedded-mysql:${project.version}</name>
<build>
<dockerFile>
${project.build.directory}/embedded-build-tmp/docker-embedded/mysql/Dockerfile</dockerFile>
<contextDir>
${project.build.directory}/embedded-build-tmp/distro</contextDir>
</build>
</image>
</images>
<buildx>
<platforms>
<platform>linux/amd64</platform>
<platform>linux/arm64</platform>
</platforms>
</buildx>
</configuration>
<executions>
<execution>
<id>Build embedded docker images</id>
<goals>
<goal>build</goal>
</goals>
<phase>package</phase>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>com.ozonehis</groupId>
<artifactId>ozone-docker-embedded</artifactId>
<type>zip</type>
<version>${ozoneDockerEmbedded}</version>
</dependency>
</dependencies>
</profile>
</profiles>
</project>
Loading

0 comments on commit 3416f76

Please sign in to comment.