--- /dev/null
+target/docker/**
\ No newline at end of file
-FROM openjdk:8-jre
+FROM openjdk:8-jre-alpine
ADD ./target/CloudAccount-0.0.1-SNAPSHOT.jar iotivity/AccountServer.jar
ADD ./target/lib/* iotivity/lib/
ENV DSM_HOST=192.168.99.100
ENV DSM_PORT=8080
-
EXPOSE 5685
-ENTRYPOINT ["java", "-jar", "AccountServer.jar"]
+
+CMD sleep 5 && java -jar AccountServer.jar
<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>org.iotivity.cloud</groupId>
+
+ <parent>
+ <groupId>org.iotivity.cloud</groupId>
+ <artifactId>parent</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ </parent>
+
<artifactId>CloudAccount</artifactId>
<version>0.0.1-SNAPSHOT</version>
<overWriteIfNewer>true</overWriteIfNewer>
</configuration>
</plugin>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <configuration>
+ <images>
+ <image>
+ <name>account</name>
+ <build>
+ <dockerFile>${project.basedir}/Dockerfile</dockerFile>
+ </build>
+ </image>
+ </images>
+ </configuration>
+ </plugin>
</plugins>
</build>
--- /dev/null
+target/docker/**
\ No newline at end of file
-FROM openjdk:8-jre
+FROM openjdk:8-jre-alpine
ADD ./target/CloudInterface-0.0.1-SNAPSHOT.jar iotivity/CloudInterface.jar
ADD ./target/lib/* iotivity/lib/
<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>org.iotivity.cloud</groupId>
+
+ <parent>
+ <groupId>org.iotivity.cloud</groupId>
+ <artifactId>parent</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ </parent>
+
<artifactId>CloudInterface</artifactId>
<version>0.0.1-SNAPSHOT</version>
<overWriteIfNewer>true</overWriteIfNewer>
</configuration>
</plugin>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <configuration>
+ <images>
+ <image>
+ <name>interface</name>
+ <build>
+ <dockerFile>${project.basedir}/Dockerfile</dockerFile>
+ </build>
+ </image>
+ </images>
+ </configuration>
+ </plugin>
</plugins>
</build>
--- /dev/null
+target/docker/**
\ No newline at end of file
-FROM openjdk:8-jre
+FROM openjdk:8-jre-alpine
ADD ./target/CloudMessageQueue-0.0.1-SNAPSHOT.jar iotivity/MessageQueue.jar
ADD ./target/lib/* iotivity/lib/
EXPOSE 5686
-CMD sleep 10
-
-ENTRYPOINT ["java", "-jar", "MessageQueue.jar"]
\ No newline at end of file
+CMD sleep 10 && java -jar MessageQueue.jar
<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>org.iotivity.cloud</groupId>
+
+ <parent>
+ <groupId>org.iotivity.cloud</groupId>
+ <artifactId>parent</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ </parent>
+
<artifactId>CloudMessageQueue</artifactId>
<version>0.0.1-SNAPSHOT</version>
<overWriteIfNewer>true</overWriteIfNewer>
</configuration>
</plugin>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <configuration>
+ <images>
+ <image>
+ <name>messagequeue</name>
+ <build>
+ <dockerFile>${project.basedir}/Dockerfile</dockerFile>
+ </build>
+ </image>
+ </images>
+ </configuration>
+ </plugin>
</plugins>
</build>
--- /dev/null
+<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>
+
+ <groupId>org.iotivity.cloud</groupId>
+ <artifactId>parent</artifactId>
+ <packaging>pom</packaging>
+ <version>0.0.1-SNAPSHOT</version>
+ <name>Iotivity Parent</name>
+ <description>Iotivity Parent module</description>
+
+ <modules>
+ <module>stack</module>
+ <module>resourceDirectory</module>
+ <module>account</module>
+ <module>interface</module>
+ <module>messageQueue</module>
+ </modules>
+
+ <properties>
+ <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+ <jdk.version>1.8</jdk.version>
+ <jetty-maven-plugin.version>9.2.11.v20150529</jetty-maven-plugin.version>
+ <maven-compiler-plugin.version>2.3.2</maven-compiler-plugin.version>
+ </properties>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <version>${maven-compiler-plugin.version}</version>
+ <configuration>
+ <source>${jdk.version}</source>
+ <target>${jdk.version}</target>
+ <encoding>${project.build.sourceEncoding}</encoding>
+ </configuration>
+ </plugin>
+ </plugins>
+
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <version>3.0.0-M1</version>
+ </plugin>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <version>0.22.1</version>
+ <configuration>
+ <useColor>true</useColor>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ </build>
+
+ <distributionManagement>
+ <repository>
+ <uniqueVersion>true</uniqueVersion>
+ <id>releases</id>
+ <url>http://106.125.46.139:8181/nexus/content/repositories/releases/</url>
+ </repository>
+ <snapshotRepository>
+ <id>snapshots</id>
+ <url>http://106.125.46.139:8181/nexus/content/repositories/snapshots/</url>
+ </snapshotRepository>
+ </distributionManagement>
+
+</project>
\ No newline at end of file
--- /dev/null
+target/docker/**
\ No newline at end of file
-FROM openjdk:8-jre
+FROM openjdk:8-jre-alpine
ADD ./target/CloudResourceDirectory-0.0.1-SNAPSHOT.jar iotivity/ResourceDirectory.jar
ADD ./target/lib/* iotivity/lib/
ENV MONGODB_PORT 27017
EXPOSE 5684
-ENTRYPOINT ["java", "-jar", "ResourceDirectory.jar"]
\ No newline at end of file
+
+CMD sleep 5 && java -jar ResourceDirectory.jar
\ No newline at end of file
<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>org.iotivity.cloud</groupId>
+
+ <parent>
+ <groupId>org.iotivity.cloud</groupId>
+ <artifactId>parent</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ </parent>
+
<artifactId>CloudResourceDirectory</artifactId>
<version>0.0.1-SNAPSHOT</version>
<overWriteIfNewer>true</overWriteIfNewer>
</configuration>
</plugin>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <configuration>
+ <images>
+ <image>
+ <name>resourcedirectory</name>
+ <build>
+ <dockerFile>${project.basedir}/Dockerfile</dockerFile>
+ </build>
+ </image>
+ </images>
+ </configuration>
+ </plugin>
</plugins>
</build>
<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>org.iotivity.cloud</groupId>
+
+ <parent>
+ <groupId>org.iotivity.cloud</groupId>
+ <artifactId>parent</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
<artifactId>CloudStack</artifactId>
<version>0.0.1-SNAPSHOT</version>
--- /dev/null
+target/docker/**
\ No newline at end of file
# DSM
-dsm.host=http://192.168.99.100:8080/dsm
+dsm.host=http://dsm:8080/dsm
#Iotivity Cloud Service
cloud.service.authprovider=Samsung
-cloud.service.host=coap+tcp://192.168.99.100:5683
+cloud.service.host=coap+tcp://106.125.46.139:5683
cloud.service.model=SecServerModel
cloud.service.modelNameKey=dmv
cloud.service.appName=SecServer
</execution>
</executions>
</plugin>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <configuration>
+ <images>
+ <image>
+ <name>alive</name>
+ <build>
+ <dockerFile>${project.basedir}/Dockerfile</dockerFile>
+ </build>
+ </image>
+ </images>
+ </configuration>
+ </plugin>
</plugins>
</build>
</project>
\ No newline at end of file
services:
mongodb:
- image: mongo
+ image: mongo:3.4
kafka-zookeeper:
- #image: kafka:2.11-0.9
- image: kafka
+ image: kafka:2.11-0.9
ports:
- "9092:9092"
- "2181:2181"
db:
- image: postgres:9.5
+ image: postgres:9.5-alpine
environment:
POSTGRES_DB: secDB
POSTGRES_PASSWORD: postgres
- "5432:5432"
iotivity-resourcedirectory:
- image: sw_resourcedirectory
+ image: resourcedirectory
iotivity-accountserver:
- image: sw_account
+ image: account
iotivity-messagequeue:
- image: sw_messagequeue
+ image: messagequeue
iotivity-interface:
- image: sw_interface
+ image: interface
ports:
- "5683:5683"
--- /dev/null
+target/docker/**
\ No newline at end of file
-FROM tomcat:7-jre8
+FROM tomcat:7-jre8-alpine
ADD ./target/dsm.war $CATALINA_HOME/webapps/dsm.war
<sourceMapOutputPath>${basedir}/src/main/webapp/resources/css</sourceMapOutputPath>
</configuration>
</plugin>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <configuration>
+ <images>
+ <image>
+ <name>dsm</name>
+ <build>
+ <dockerFile>${project.basedir}/Dockerfile</dockerFile>
+ </build>
+ </image>
+ </images>
+ </configuration>
+ </plugin>
</plugins>
</build>
</project>
\ No newline at end of file
--- /dev/null
+target/docker/**
\ No newline at end of file
-FROM openjdk:8-jre
+FROM openjdk:8-jre-alpine
ADD ./target/mq-1.0.0-SNAPSHOT.jar servers/mq.jar
</execution>
</executions>
</plugin>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <configuration>
+ <images>
+ <image>
+ <name>mq</name>
+ <build>
+ <dockerFile>${project.basedir}/Dockerfile</dockerFile>
+ </build>
+ </image>
+ </images>
+ </configuration>
+ </plugin>
</plugins>
</build>
</project>
\ No newline at end of file
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.0.0-M1</version>
</plugin>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <version>0.22.1</version>
+ <configuration>
+ <useColor>true</useColor>
+ </configuration>
+ </plugin>
</plugins>
</pluginManagement>
</build>
--- /dev/null
+target/docker/**
\ No newline at end of file
--- /dev/null
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You 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.
+# see kafka.server.KafkaConfig for additional details and defaults
+
+############################# Server Basics #############################
+
+# The id of the broker. This must be set to a unique integer for each broker.
+broker.id=0
+
+############################# Socket Server Settings #############################
+
+listeners=PLAINTEXT://:9092
+
+# The port the socket server listens on
+#port=9092
+
+# Hostname the broker will bind to. If not set, the server will bind to all interfaces
+#host.name=localhost
+
+# Hostname the broker will advertise to producers and consumers. If not set, it uses the
+# value for "host.name" if configured. Otherwise, it will use the value returned from
+# java.net.InetAddress.getCanonicalHostName().
+advertised.host.name=192.168.99.100
+
+# The port to publish to ZooKeeper for clients to use. If this is not set,
+# it will publish the same port that the broker binds to.
+#advertised.port=<port accessible by clients>
+
+# The number of threads handling network requests
+num.network.threads=3
+
+# The number of threads doing disk I/O
+num.io.threads=8
+
+# The send buffer (SO_SNDBUF) used by the socket server
+socket.send.buffer.bytes=102400
+
+# The receive buffer (SO_RCVBUF) used by the socket server
+socket.receive.buffer.bytes=102400
+
+# The maximum size of a request that the socket server will accept (protection against OOM)
+socket.request.max.bytes=104857600
+
+
+############################# Log Basics #############################
+
+# A comma seperated list of directories under which to store log files
+log.dirs=/tmp/kafka-logs
+
+# The default number of log partitions per topic. More partitions allow greater
+# parallelism for consumption, but this will also result in more files across
+# the brokers.
+num.partitions=1
+
+# The number of threads per data directory to be used for log recovery at startup and flushing at shutdown.
+# This value is recommended to be increased for installations with data dirs located in RAID array.
+num.recovery.threads.per.data.dir=1
+
+############################# Log Flush Policy #############################
+
+# Messages are immediately written to the filesystem but by default we only fsync() to sync
+# the OS cache lazily. The following configurations control the flush of data to disk.
+# There are a few important trade-offs here:
+# 1. Durability: Unflushed data may be lost if you are not using replication.
+# 2. Latency: Very large flush intervals may lead to latency spikes when the flush does occur as there will be a lot of data to flush.
+# 3. Throughput: The flush is generally the most expensive operation, and a small flush interval may lead to exceessive seeks.
+# The settings below allow one to configure the flush policy to flush data after a period of time or
+# every N messages (or both). This can be done globally and overridden on a per-topic basis.
+
+# The number of messages to accept before forcing a flush of data to disk
+#log.flush.interval.messages=10000
+
+# The maximum amount of time a message can sit in a log before we force a flush
+#log.flush.interval.ms=1000
+
+############################# Log Retention Policy #############################
+
+# The following configurations control the disposal of log segments. The policy can
+# be set to delete segments after a period of time, or after a given size has accumulated.
+# A segment will be deleted whenever *either* of these criteria are met. Deletion always happens
+# from the end of the log.
+
+# The minimum age of a log file to be eligible for deletion
+log.retention.hours=168
+
+# A size-based retention policy for logs. Segments are pruned from the log as long as the remaining
+# segments don't drop below log.retention.bytes.
+#log.retention.bytes=1073741824
+
+# The maximum size of a log segment file. When this size is reached a new log segment will be created.
+log.segment.bytes=1073741824
+
+# The interval at which log segments are checked to see if they can be deleted according
+# to the retention policies
+log.retention.check.interval.ms=300000
+
+############################# Zookeeper #############################
+
+# Zookeeper connection string (see zookeeper docs for details).
+# This is a comma separated host:port pairs, each corresponding to a zk
+# server. e.g. "127.0.0.1:3000,127.0.0.1:3001,127.0.0.1:3002".
+# You can also append an optional chroot string to the urls to specify the
+# root directory for all kafka znodes.
+zookeeper.connect=localhost:2181
+
+# Timeout in ms for connecting to zookeeper
+zookeeper.connection.timeout.ms=6000
+
+delete.topic.enable = true
+
+
--- /dev/null
+<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>
+
+ <parent>
+ <groupId>samsung.swsec.services</groupId>
+ <artifactId>parent</artifactId>
+ <version>1.0.0</version>
+ </parent>
+
+ <artifactId>kafka</artifactId>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <configuration>
+ <images>
+ <image>
+ <name>kafka:2.11-0.9</name>
+ <build>
+ <dockerFile>${project.basedir}/Dockerfile</dockerFile>
+ </build>
+ </image>
+ </images>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
\ No newline at end of file
# Hostname the broker will advertise to producers and consumers. If not set, it uses the
# value for "host.name" if configured. Otherwise, it will use the value returned from
# java.net.InetAddress.getCanonicalHostName().
-advertised.host.name=192.168.99.100
+advertised.host.name=106.125.46.139
# The port to publish to ZooKeeper for clients to use. If this is not set,
# it will publish the same port that the broker binds to.
--- /dev/null
+target/docker/**
\ No newline at end of file
--- /dev/null
+<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>
+
+ <parent>
+ <groupId>samsung.swsec.services</groupId>
+ <artifactId>parent</artifactId>
+ <version>1.0.0</version>
+ </parent>
+
+ <artifactId>mongo</artifactId>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <configuration>
+ <images>
+ <image>
+ <name>mongo:3.4</name>
+ <build>
+ <dockerFile>${project.basedir}/Dockerfile</dockerFile>
+ </build>
+ </image>
+ </images>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
\ No newline at end of file
--- /dev/null
+<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>
+
+ <groupId>samsung.swsec.services</groupId>
+ <artifactId>parent</artifactId>
+ <version>1.0.0</version>
+ <packaging>pom</packaging>
+ <name>Swsec Services</name>
+ <description>Swsec Services module</description>
+
+ <modules>
+ <module>kafka</module>
+ <module>mongo</module>
+ <module>postgres</module>
+ </modules>
+
+ <build>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <version>3.0.0-M1</version>
+ </plugin>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <version>0.22.1</version>
+ <configuration>
+ <useColor>true</useColor>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ </build>
+
+</project>
\ No newline at end of file
+++ /dev/null
-FROM postgres:9.5
-
-
-
-
-
-
-
-
--- /dev/null
+target/docker/**
\ No newline at end of file
--- /dev/null
+FROM postgres:9.5-alpine
+
+
+
+
+
+
+
+
+
--- /dev/null
+<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>
+
+ <parent>
+ <groupId>samsung.swsec.services</groupId>
+ <artifactId>parent</artifactId>
+ <version>1.0.0</version>
+ </parent>
+
+ <artifactId>postgres</artifactId>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <configuration>
+ <images>
+ <image>
+ <name>postgres:9.5-alpine</name>
+ <build>
+ <dockerFile>${project.basedir}/Dockerfile</dockerFile>
+ </build>
+ </image>
+ </images>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
\ No newline at end of file