forked from spring-petclinic/spring-petclinic-microservices
-
Notifications
You must be signed in to change notification settings - Fork 195
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Adapt for ASA-E
- Loading branch information
Showing
66 changed files
with
19,039 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
NODE_ENV=development |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
NODE_ENV=production |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
registry=https://registry.npmjs.org/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# Frontend for PetClinic project | ||
|
||
This module is the frontend part of the PetClinic project, it provides the same features as the `spring-petclinic-api-gateway` module. | ||
When deploying to Azure Spring Apps enterprise plan, you can use the managed component Spring Cloud Gateway on Azure Spring Apps, which is more efficient and cost-effective. | ||
|
||
## Run locally | ||
|
||
Please note that supporting services (Config and Discovery Server) must be started before any other application. | ||
|
||
Enter the project root directory and open a terminal to start Config Server: | ||
|
||
```shell | ||
./mvnw spring-boot:run -pl spring-petclinic-config-server | ||
``` | ||
|
||
Open a new terminal to start Discovery Server: | ||
|
||
```shell | ||
./mvnw spring-boot:run -pl spring-petclinic-discovery-server | ||
``` | ||
|
||
For Customers, Vets, and Visits services, open new terminal in turn and execute the following commands: | ||
|
||
```shell | ||
./mvnw spring-boot:run -pl spring-petclinic-customers-service | ||
./mvnw spring-boot:run -pl spring-petclinic-vets-service | ||
./mvnw spring-boot:run -pl spring-petclinic-visits-service | ||
``` | ||
|
||
For Gateway service, it's required to enable the Spring profile `deployment` to enable the static resource proxy, open a new terminal and execute the following command: | ||
|
||
```shell | ||
./mvnw spring-boot:run -Dspring-boot.run.profiles=default,development -pl spring-petclinic-api-gateway | ||
``` | ||
|
||
Install [Node.js 16.20 LTS](https://nodejs.org/en/download/) if you don't have it already. | ||
|
||
Enter the project `spring-petclinic-frontend` directory and open a new terminal to install dependencies and run the frontend: | ||
|
||
```shell | ||
npm install | ||
npm run start | ||
```` | ||
|
||
If everything goes well, you can access the PetClinic at given location: | ||
* Gateway - http://localhost:8080 | ||
* Frontend - http://localhost:3000 |
Oops, something went wrong.