config and deploy stuff

This commit is contained in:
austin 2024-05-11 16:04:13 -04:00
parent 2905a15364
commit 0cd3f0a619
2 changed files with 29 additions and 0 deletions

15
docker-compose.yml Normal file
View File

@ -0,0 +1,15 @@
version: "3"
services:
server:
image: tomcat:9
restart: always
container_name: survey-server
environment:
- MY_VAR=1000
volumes:
- ./webapps:/usr/local/tomcat/webapps
- ./db:/usr/local/tomcat/db
- ./config:/usr/local/tomcat/config
ports:
- "8080:8080"

14
test.sh Normal file
View File

@ -0,0 +1,14 @@
# assemble FE
cd ~/p/self-survey-fe
npm run build
cd ~/p/SelfSurvey-server-master/src/main/resources/static
rm -rf ./*
cp -r ~/p/self-survey-fe/dist/* ~/p/SelfSurvey-server-master/src/main/resources/static/
# assemble BE
cd ~/p/SelfSurvey-server-master/
mvn clean package
cd ~/Documents/apache-tomcat-9.0.89/webapps/
rm -rf ./ROOT.war ./ROOT
cp ~/p/SelfSurvey-server-master/target/self-survey.war ~/Documents/apache-tomcat-9.0.89/webapps/ROOT.war
cd ~/Documents/apache-tomcat-9.0.89/bin/
./catalina.sh run