Merge remote-tracking branch 'upstream/main' into main

This commit is contained in:
machih 2021-05-28 17:10:00 +09:00
commit 6d68821d8f
3 changed files with 11 additions and 5 deletions

View file

@ -4,6 +4,6 @@ jdk: oraclejdk8
services:
- docker
before_script:
- '[ "${TRAVIS_BRANCH}" = "main" ] && docker login -u springbuildmaster -p "$DOCKERHUB_PASSWORD"'
- '[ "${TRAVIS_PULL_REQUEST}" != "false" ] || [ "${TRAVIS_BRANCH}" != "main" ] || docker login -u springbuildmaster -p "$DOCKERHUB_PASSWORD"'
script:
- ./mvnw spring-boot:build-image -D spring-boot.build-image.imageName=springio/petclinic && [ "${TRAVIS_BRANCH}" = "main" ] && docker push springio/petclinic
- ./mvnw spring-boot:build-image -D spring-boot.build-image.imageName=springio/petclinic && ([ "${TRAVIS_BRANCH}" != "main" ] || docker push springio/petclinic)

View file

@ -24,6 +24,8 @@ Or you can run it from Maven directly using the Spring Boot Maven plugin. If you
./mvnw spring-boot:run
```
> NOTE: Windows users should set `git config core.autocrlf true` to avoid format assertions failing the build (use `--global` to set that flag globally).
## In case you find a bug/suggested improvement for Spring Petclinic
Our issue tracker is available here: https://github.com/spring-projects/spring-petclinic/issues
@ -48,7 +50,7 @@ Further documentation is provided [here](https://github.com/spring-projects/spri
### Prerequisites
The following items should be installed in your system:
* Java 8 or newer.
* Java 8 or newer (full JDK not a JRE).
* git command line tool (https://help.github.com/articles/set-up-git)
* Your preferred IDE
* Eclipse with the m2e plugin. Note: when m2e is available, there is an m2 icon in `Help -> About` dialog. If m2e is

View file

@ -21,10 +21,14 @@
2) (Once only) create the PetClinic database and user by executing the "db/mysql/user.sql"
scripts. You can connect to the database running in the docker container using
`mysql -u root -h localhost --protocol tcp`, but you don't need to run the script there
because the petclinic user is already set up if you use the provided `docker-compose.yaml`.
because the petclinic user is already set up if you use the provided `docker-compose.yml`.
3) Run the app with `spring.profiles.active=mysql` (e.g. as a System property via the command
line, but any way that sets that property in a Spring Boot app should work).
line, but any way that sets that property in a Spring Boot app should work). For example use
mvn spring-boot:run -Dspring-boot.run.profiles=mysql
To activate the profile on the command line.
N.B. the "petclinic" database has to exist for the app to work with the JDBC URL value
as it is configured by default. This condition is taken care of automatically by the