PACR analyzes commits in repositories.
- Install mysql-server
- Create user 'pacr' with password 'pacr1'.
- Create user 'pacr2' with password 'pacr2'
- Create database 'pacr'
- Create database 'pacrtest'
- Grant all privileges on database to 'pacr'
- Grant only privileges to schema 'pacrtest' to 'pacr2'
- Start mysql-server
- Install Java 13
- Clone project
- Import as existing maven project to IDE
- Start WebappBackendApplication
- Install node
- Install the angular-cli
- Clone project
- Open terminal
- Navigate to
frontend
directory - Run
npm install
- Run
ng serve
- Open
localhost:4200
in browser
Optional: (currently required for diagrams)
- Clone prototypes
- Navigate to directory
rest
- Run
node main.js
in terminal
- Install Java 13
- Start BenchmarkerApplication
- Follow steps 1-8 from setup database
- Follow steps 1-3 from setup backend
- Run
mvn package
- Deploy jar to desired location with
ssh.key
(SSH private key) andssh.pub
(SSH public key) in the same folder. - Execute the jar file
- Follow steps 1-6 from setup frontend
- Run
ng build --prod --aot
in frontend directory - Deploy contents of
frontend/dist
to desired location on webserver (for example copy files to /www directory of apache) - Configure webserver to redirect missing pages to
index.html
- Follow step 1 from the benchmarker setup.
- Run
mvn package
. - Deploy the jar to desired location.
- Create a directory
runner
and place thebench
file in it. - To set the IP-address of the backend, create a file
application.properties
in the same directory as the jar file and addipWebApp=[insertIP]
.
If you want to change the default values of the app, simply create a file called application.properties
next to the jar file and add the line with the path variable you want to change.
The default application.properties looks like this:
publicKeyPath = /ssh.pub
privateKeyPath = /ssh.key
allowedOrigins = *
gitRepositoriesPath = /repositories
gitRepositoryPullIntervalDefault = 30
repository.colors = #ff8091,#8c6973,#330d2b,#532080,#1d00d9,#204680,#00ccff,#39e6da,#394d3e,#b4e6ac,#999673,#ffaa00,#66381a,#400900,#f20000,#d9003a,#661a42,#cc00ff,#1a0040,#c8bfff,#001b33,#103640,#238c77,#008011,#414d13,#7f6600,#33260d,#7f2200,#b26559,#403030,#ffbfd0,#cc3399,#e680ff,#73698c,#005ce6,#0099e6,#4d8a99,#40ff73,#003307,#dae639,#e5cf73,#cc7033,#f2c6b6,#ff0000
adminPasswordHashPath = /adminPasswordHash.txt
secretPath = /secret.txt
ignoreTag = #pacr-ignore
labelTag = #pacr-label
spring.jpa.hibernate.ddl-auto=update
spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL5InnoDBDialect
spring.datasource.url=jdbc:mysql://${MYSQL_HOST:localhost}:3306/pacr
spring.datasource.username=pacr
spring.datasource.password=pacr
The default application.properties looks like this:
privateKeyPath=/ssh.key
repositoryWorkingDir=/repositories
relPathToWorkingDir=..
ipWebApp=127.0.0.1:8080
runnerFile=bench
runnerDir=runner
server.port=0