Skip to content

Commit

Permalink
initial commit to check setup the project as per template for reefer …
Browse files Browse the repository at this point in the history
…monitoring commercial reference implementation
  • Loading branch information
cmsdroff committed Nov 21, 2023
1 parent c69e57a commit b527fe2
Show file tree
Hide file tree
Showing 10 changed files with 30 additions and 30 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ ENV db_hostname dcsa_db
COPY run-in-container.sh /run.sh
RUN chmod +x /run.sh
COPY application/src/main/resources/application.yml .
COPY application/target/dcsa-template-application.jar .
COPY application/target/dcsa-rmc-application.jar .
CMD ["/run.sh"]
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# DCSA Project Template
# DCSA RMC - Reefer Monitoring Commercial

**[RECOMMENDED]** <br>
Setup a Github Personal Access Token as mentioned [here](https://github.com/dcsaorg/DCSA-Core/blob/master/README.md#how-to-use-dcsa-core-packages).
Expand All @@ -12,8 +12,8 @@ Setup a Github Personal Access Token as mentioned [here](https://github.com/dcsa
- Update GitHub Actions

### Checklist to setup the `template` for your project:
- [ ] Rename the project, DCSA-{ProjectName} (e.g. DCSA-TNT)
- [ ] `DCSA-Project-Template > pom.xml`
- [x] Rename the project, DCSA-{ProjectName} (e.g. DCSA-TNT)
- [x] `DCSA-Project-Template > pom.xml`
```xml
<groupId>org.dcsa.template</groupId>
<artifactId>dcsa-template-parent</artifactId>
Expand All @@ -24,52 +24,52 @@ Setup a Github Personal Access Token as mentioned [here](https://github.com/dcsa
<project.name>DCSA Template</project.name>
</properties>
```
- [ ] `DCSA-Project-Template > domain > pom.xml`
- [x] `DCSA-Project-Template > domain > pom.xml`
```xml
<parent>
<groupId>org.dcsa.template</groupId>
<artifactId>dcsa-template-parent</artifactId>
...
</parent>
```
- [ ] `DCSA-Project-Template > transfer-obj > pom.xml`
- [x] `DCSA-Project-Template > transfer-obj > pom.xml`
```xml
<parent>
<groupId>org.dcsa.template</groupId>
<artifactId>dcsa-template-parent</artifactId>
...
</parent>
```
- [ ] `DCSA-Project-Template > service > pom.xml`
- [x] `DCSA-Project-Template > service > pom.xml`
```xml
<parent>
<groupId>org.dcsa.template</groupId>
<artifactId>dcsa-template-parent</artifactId>
...
</parent>
```
- [ ] `DCSA-Project-Template > application > pom.xml`
- [x] `DCSA-Project-Template > application > pom.xml`
```xml
<parent>
<groupId>org.dcsa.template</groupId>
<artifactId>dcsa-template-parent</artifactId>
...
</parent>
```
- [ ] Rename package `DCSA-Project-Template > application > src > main > java > org.dcsa.template`
- [ ] `DCSA-Project-Template > application > src > main > resources > application.yml`
- [x] Rename package `DCSA-Project-Template > application > src > main > java > org.dcsa.template`
- [x] `DCSA-Project-Template > application > src > main > resources > application.yml`
```yaml
spring:
application:
name: dcsa-template
datasource:
url: jdbc:postgresql://${db_hostname}/dcsa_template
```
- [ ] `DCSA-Project-Template > Dockerfile`
- [x] `DCSA-Project-Template > Dockerfile`
```dockerfile
COPY application/target/dcsa-template-application.jar .
```
- [ ] `DCSA-Project-Template > docker-compose.yml`
- [x] `DCSA-Project-Template > docker-compose.yml`
```yaml
dcsa-template:
container_name: dcsa_template
Expand Down
4 changes: 2 additions & 2 deletions application/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.dcsa.template</groupId>
<artifactId>dcsa-template-parent</artifactId>
<groupId>org.dcsa.rmc</groupId>
<artifactId>dcsa-rmc-parent</artifactId>
<version>${revision}${sha1}${changelist}</version>
</parent>

Expand Down
4 changes: 2 additions & 2 deletions application/src/main/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ dcsa:

spring:
application:
name: dcsa-template
name: dcsa-rmc
datasource:
driver-class-name: org.postgresql.Driver
url: jdbc:postgresql://${db_hostname}/dcsa_template
url: jdbc:postgresql://${db_hostname}/dcsa_rmc
username: dcsa_db_owner
jpa:
database-platform: org.hibernate.dialect.PostgreSQLDialect
Expand Down
4 changes: 2 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: '3.5'

services:
dcsa-template:
container_name: dcsa_template
container_name: dcsa_rmc
build:
.
ports:
Expand All @@ -24,7 +24,7 @@ services:

dcsa-test-db:
image: postgres:15-alpine
container_name: dcsa_template_db
container_name: dcsa_rmc_db
environment:
POSTGRES_PASSWORD: "change_this_password"
volumes:
Expand Down
4 changes: 2 additions & 2 deletions domain/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.dcsa.template</groupId>
<artifactId>dcsa-template-parent</artifactId>
<groupId>org.dcsa.rmc</groupId>
<artifactId>dcsa-rmc-parent</artifactId>
<version>${revision}${sha1}${changelist}</version>
</parent>

Expand Down
12 changes: 6 additions & 6 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@
<version>1.5-SNAPSHOT</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<groupId>org.dcsa.template</groupId>
<artifactId>dcsa-template-parent</artifactId>
<groupId>org.dcsa.rmc</groupId>
<artifactId>dcsa-rmc-parent</artifactId>
<version>${revision}${sha1}${changelist}</version>
<packaging>pom</packaging>
<name>${project.name}</name>
<description>${project.name} Project</description>
<description>${project.name} Reefer Monitoring Commercial </description>

<properties>
<!-- Define DCSA-Project version -->
Expand All @@ -30,9 +30,9 @@
<!-- End: Define Shared kernel version -->

<hibernate-types.version>2.21.1</hibernate-types.version>
<group.id>org.dcsa.template</group.id>
<artifact.id>dcsa-template</artifact.id>
<project.name>DCSA Template</project.name>
<group.id>org.dcsa.rmc</group.id>
<artifact.id>dcsa-rmc</artifact.id>
<project.name>DCSA-RMC</project.name>
</properties>

<modules>
Expand Down
4 changes: 2 additions & 2 deletions service/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.dcsa.template</groupId>
<artifactId>dcsa-template-parent</artifactId>
<groupId>org.dcsa.rmc</groupId>
<artifactId>dcsa-rmc-parent</artifactId>
<version>${revision}${sha1}${changelist}</version>
</parent>

Expand Down
4 changes: 2 additions & 2 deletions transfer-obj/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.dcsa.template</groupId>
<artifactId>dcsa-template-parent</artifactId>
<groupId>org.dcsa.rmc</groupId>
<artifactId>dcsa-rmc-parent</artifactId>
<version>${revision}${sha1}${changelist}</version>
</parent>

Expand Down

0 comments on commit b527fe2

Please sign in to comment.