mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-20 23:05:49 +00:00
updated: changed to war, ebs, and rds db path changed
This commit is contained in:
parent
d8fcd11e67
commit
9fd593cdcc
4 changed files with 31 additions and 8 deletions
1
pom.xml
1
pom.xml
|
@ -6,6 +6,7 @@
|
||||||
<groupId>org.springframework.samples</groupId>
|
<groupId>org.springframework.samples</groupId>
|
||||||
<artifactId>spring-petclinic</artifactId>
|
<artifactId>spring-petclinic</artifactId>
|
||||||
<version>3.3.0-SNAPSHOT</version>
|
<version>3.3.0-SNAPSHOT</version>
|
||||||
|
<packaging>war</packaging> <!-- Setting packaging type to war -->
|
||||||
|
|
||||||
<parent>
|
<parent>
|
||||||
<groupId>org.springframework.boot</groupId>
|
<groupId>org.springframework.boot</groupId>
|
||||||
|
|
|
@ -1,7 +1,9 @@
|
||||||
# database init, supports mysql too
|
# database init, supports mysql too
|
||||||
database=mysql
|
database=mysql
|
||||||
spring.datasource.url=${MYSQL_URL:jdbc:mysql://localhost/petclinic}
|
spring.datasource.url=${MYSQL_URL:jdbc:mysql://path:3306/petclinic}
|
||||||
spring.datasource.username=${MYSQL_USER:petclinic}
|
spring.datasource.username=${MYSQL_USER:secret}
|
||||||
spring.datasource.password=${MYSQL_PASS:petclinic}
|
spring.datasource.password=${MYSQL_PASS:secret}
|
||||||
|
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
|
||||||
|
|
||||||
# SQL is written to be idempotent so this is safe
|
# SQL is written to be idempotent so this is safe
|
||||||
spring.sql.init.mode=always
|
spring.sql.init.mode=always
|
||||||
|
|
|
@ -3,6 +3,12 @@ database=h2
|
||||||
spring.sql.init.schema-locations=classpath*:db/${database}/schema.sql
|
spring.sql.init.schema-locations=classpath*:db/${database}/schema.sql
|
||||||
spring.sql.init.data-locations=classpath*:db/${database}/data.sql
|
spring.sql.init.data-locations=classpath*:db/${database}/data.sql
|
||||||
|
|
||||||
|
# used to elastic bean stalk
|
||||||
|
#server.port=5000
|
||||||
|
|
||||||
|
#active spring profile
|
||||||
|
spring.profiles.active=mysql
|
||||||
|
|
||||||
# Web
|
# Web
|
||||||
spring.thymeleaf.mode=HTML
|
spring.thymeleaf.mode=HTML
|
||||||
|
|
||||||
|
|
|
@ -48,8 +48,22 @@
|
||||||
<br />
|
<br />
|
||||||
<h2>Pets and Visits</h2>
|
<h2>Pets and Visits</h2>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
|
|
||||||
|
<h3> Pet Photograph</h3>
|
||||||
|
|
||||||
|
<!-- TODO add the image from S3 for the respective pet -->
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-md-12">
|
||||||
|
<img class="img-responsive" src="../static/resources/images/pets.png" th:src="@{/resources/images/pets.png}"/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<br>
|
||||||
|
|
||||||
<tr th:each="pet : ${owner.pets}">
|
<tr th:each="pet : ${owner.pets}">
|
||||||
<td valign="top">
|
<td valign="top">
|
||||||
<dl class="dl-horizontal">
|
<dl class="dl-horizontal">
|
||||||
|
|
Loading…
Reference in a new issue