|
|
|
# Online Server
|
|
|
|
Install the BudgetMasterServer on an online accessible server to allow connections from multiple clients.
|
|
|
|
|
|
|
|
### Step 1: Put BudgetMasterServer.jar in desired location
|
|
|
|
|
|
|
|
|
|
|
|
### Step 2: Put settings.json in same location
|
|
|
|
|
|
|
|
|
|
|
|
### Step 3a: Use a mysql database
|
|
|
|
- Create an empty mysql database
|
|
|
|
- Fill in the according lines in `settings.json`:
|
|
|
|
`"databaseType": "mysql",`
|
|
|
|
`"databaseUrl": "your_database_url_and_port",` (e.g. localhost:3306/)
|
|
|
|
`"databaseName": "your_database_name",`
|
|
|
|
`"databaseUsername": "your_database_user_name",`
|
|
|
|
`"databasePassword": "your_password"`
|
|
|
|
|
|
|
|
- proceed with step 4a or 4b
|
|
|
|
|
|
|
|
|
|
|
|
### Step 3b: Use a sqlite database
|
|
|
|
- Fill in the according lines in `settings.json`:
|
|
|
|
`"databaseType": "sqlite",`
|
|
|
|
`"databaseUrl": "save_path_for_the_database_file",`
|
|
|
|
|
|
|
|
___Note:__ If you don't provide a `"databaseURL"` the database file will be saved in the same location as BudgetMasterServer_
|
|
|
|
___Note:__ `"databaseName"`, `"databaseUsername"` and `"databasePassword"` are not relevant for sqlite_
|
|
|
|
|
|
|
|
- proceed with step 4a or 4b
|
|
|
|
|
|
|
|
### Step 4a: Use BudgetMasterServer in an local area network
|
|
|
|
If you are going to use the BudgetMasterServer in a local area network where it isn't exposed to the internet you could use the default certificate and keystore that comes bundled with the BudgetMasterServer.
|
|
|
|
To do this you have to set the `keystorePath` to `"default"` and the `keystorePassword` to `"BudgetMaster"` in `settings.json`.
|
|
|
|
|
|
|
|
___Note:__ It is technically possible to use the default keystore even if the BudgetMasterServer could be accessed on the internet.
|
|
|
|
This is definetly __NOT__ recommended as the certificate integrity and communication security will be harmed!_
|
|
|
|
|
|
|
|
### Step 4b: Use BudgetMasterServer with internet access
|
|
|
|
- Get a HTTPS certificate or create a self-signed one
|
|
|
|
_The communication between the server and client will be HTTPS-encrypted so you will need a certificate for the server._
|
|
|
|
- Create a Java Keystore holding your certificate
|
|
|
|
_[How to create a keystore from a certificate](https://github.com/deadlocker8/BudgetMaster/wiki/HTTPS)_
|
|
|
|
|
|
|
|
- fill in the corresponding lines in `settings.json`:
|
|
|
|
`"keystorePath": "path_to_keystore_file",`
|
|
|
|
`"keystorePassword": "your_keystore_password"`
|
|
|
|
|
|
|
|
### Step 5: Launch BudgetMasterServer.jar
|
|
|
|
all neccessary tables should be created automatically
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
___Hint:__ If you encounter any problems or errors please have a look into the generated error.log in the same directory as the BudgetMasterServer.jar_ |