|
| 1 | +--- |
| 2 | +title: Docker Team Premium |
| 3 | +weight: 30 |
| 4 | +--- |
| 5 | + |
| 6 | +Typical Team Premium installation consists of two components: |
| 7 | +- DbGate server docker container |
| 8 | +- Database server (MS SQL, MySQL, PostgreSQL, Oracle) - internal storage database for connections, users and roles |
| 9 | + |
| 10 | +## DbGate Server Docker Container |
| 11 | +User [DbGate Team Premium image](https://hub.docker.com/r/dbgate/dbgate-premium) from Docker Hub: |
| 12 | +``` |
| 13 | +docker pull dbgate/dbgate-premium |
| 14 | +``` |
| 15 | + |
| 16 | +DbGate Team Premium container requires some environment variables to be set: |
| 17 | +- `STORAGE_SERVER`, `STORAGE_DATABASE`, `STORAGE_USER`, `STORAGE_PASSWORD`, `STORAGE_ENGINE` - defines connection to internal storage database |
| 18 | + |
| 19 | +See [environment variables documentation](/env-variables/#team-premium-edition-configuration) for more details about available environment variables. |
| 20 | + |
| 21 | +In fact, DbGate Team Premium has very low resource consumption, but for best performance we recommend following configuration (for 10 concurrent users): |
| 22 | +- Minimum 2 CPU cores |
| 23 | +- Minimum 2 GB RAM |
| 24 | +- Minimum 10 GB free disk space |
| 25 | + |
| 26 | +If you want to use disk files for storage of user files (like query results export), you should map `/root/.dbgate` path in container. |
| 27 | + |
| 28 | +```yaml |
| 29 | + volumes: |
| 30 | + - dbgate-data:/root/.dbgate |
| 31 | +``` |
| 32 | +
|
| 33 | +## Stateless/Statuefullness |
| 34 | +DbGate container is statefull. |
| 35 | +
|
| 36 | +The following data is stored inside container: |
| 37 | +* Logged user sessions |
| 38 | +* Query execution states |
| 39 | +* Temporary files (like results) |
| 40 | +* Opened database transactions |
| 41 | +* Opened database connections |
| 42 | +
|
| 43 | +It is not possible to run correctly multiple DbGate containers behind load balancer, because the data above is not shared between containers. |
| 44 | +
|
| 45 | +## DbGate Server from NPM |
| 46 | +If your infrastructure does not support Docker, you could use [DbGate Team Premium NPM package](https://www.npmjs.com/package/dbgate-serve-premium): |
| 47 | +``` |
| 48 | +npm install -g dbgate-serve-premium |
| 49 | +``` |
| 50 | + |
| 51 | +## Process isolation |
| 52 | +DbGate Team Premium uses process isolation on database connection level, so multiple users could use same database server without interference. Process forked from DbGate grows with number of active users and connections, so make sure your server has enough resources. |
| 53 | +Following entities are isolated into new process: |
| 54 | +* Server connections |
| 55 | +* Database connections |
| 56 | +* Query sessions |
| 57 | +* Export/import job execution |
| 58 | +* SSH tunneling |
0 commit comments