-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.sh
More file actions
25 lines (19 loc) · 726 Bytes
/
build.sh
File metadata and controls
25 lines (19 loc) · 726 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/bin/bash
#building react
echo "Building React app..."
cd react
npm install # Install dependencies if not already installed
npm run build # Build the React app
# copying react build into springboot static
# -- Also copying index.html into template folder for Spring Boot
echo "Copying React build to Spring Boot static folder..."
cp -r build/* ../Linux-Labyrinth/src/main/resources/static/
cp -r ../Linux-Labyrinth/src/main/resources/static/index.html ../Linux-Labyrinth/src/main/resources/templates/
# building springboot
echo "Building Spring Boot app..."
cd ../Linux-Labyrinth
mvn clean install
# running springboot
echo "Running Spring Boot app..."
mvn spring-boot:run
echo "Build and deployment complete!"