diff --git a/pom.xml b/pom.xml index a9bbd2959..471958b49 100644 --- a/pom.xml +++ b/pom.xml @@ -6,6 +6,7 @@ org.springframework.samples spring-petclinic 3.3.0-SNAPSHOT + war org.springframework.boot @@ -221,7 +222,7 @@ spring-boot-maven-plugin - build-info @@ -385,7 +386,7 @@ - org.eclipse.m2e @@ -443,4 +444,4 @@ - \ No newline at end of file + diff --git a/src/main/resources/application-mysql.properties b/src/main/resources/application-mysql.properties index e23dfa605..68176a20d 100644 --- a/src/main/resources/application-mysql.properties +++ b/src/main/resources/application-mysql.properties @@ -1,7 +1,9 @@ # database init, supports mysql too database=mysql -spring.datasource.url=${MYSQL_URL:jdbc:mysql://localhost/petclinic} -spring.datasource.username=${MYSQL_USER:petclinic} -spring.datasource.password=${MYSQL_PASS:petclinic} +spring.datasource.url=${MYSQL_URL:jdbc:mysql://path:3306/petclinic} +spring.datasource.username=${MYSQL_USER:secret} +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 spring.sql.init.mode=always diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties index 5d3eeed32..3568910cd 100644 --- a/src/main/resources/application.properties +++ b/src/main/resources/application.properties @@ -3,6 +3,12 @@ database=h2 spring.sql.init.schema-locations=classpath*:db/${database}/schema.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 spring.thymeleaf.mode=HTML diff --git a/src/main/resources/templates/owners/ownerDetails.html b/src/main/resources/templates/owners/ownerDetails.html index 15bca4ad2..cf972a15e 100644 --- a/src/main/resources/templates/owners/ownerDetails.html +++ b/src/main/resources/templates/owners/ownerDetails.html @@ -47,9 +47,23 @@

Pets and Visits

- + + + - + +

Pet Photograph

+ + + +
+
+ +
+
+ +
+