Skip to content

Commit 1c83107

Browse files
committed
Update manual
1 parent 9ed2c45 commit 1c83107

File tree

5 files changed

+112
-106
lines changed

5 files changed

+112
-106
lines changed

manual/docs/01-getstarted/05-firstrun/configfile.md

+3-16
Original file line numberDiff line numberDiff line change
@@ -61,20 +61,6 @@ or
6161

6262
## DB configuration
6363

64-
> Choose database
65-
66-
| name | type | default value | description |
67-
| ---- |:----:| -------------- | ----- |
68-
|`daikoku.storage` | string | "postgres" | You can use mongo or postgres database. mongoDb is deprecated and will be no longer supported in the next major release |
69-
70-
71-
> Mongo configuration
72-
73-
| name | type | default value | description |
74-
| ---- |:----:| -------------- | ----- |
75-
|`mongodb.uri` | string | "mongodb://localhost:27017/daikoku" | the uri to mongdb datastore |
76-
77-
7864
> Postgres configuration
7965
8066
| name | type | default value | description |
@@ -199,8 +185,9 @@ daikoku {
199185
}
200186
}
201187
202-
mongodb {
203-
uri = "mongodb://localhost:27017/daikoku"
188+
postgres {
189+
database = "daikoku_test"
190+
poolSize = 4
204191
}
205192
206193

manual/docs/01-getstarted/05-firstrun/env.md

+8-3
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@ key = ${?DAIKOKU_OTOROSHI_SYNC_KEY}
2929
cron = ${?DAIKOKU_OTOROSHI_SYNC_CRON}
3030
instance = ${?INSTANCE_NUMBER}
3131
cron = ${?DAIKOKU_OTOROSHI_SYNC_CRON}
32-
uri = ${?MONGODB_URI}
33-
uri = ${?MONGODB_ADDON_URI}
3432
http.port = ${?PORT}
3533
https.port = ${?HTTPS_PORT}
3634
key = ${?PLAY_CRYPTO_SECRET}
@@ -50,5 +48,12 @@ database = ${?DAIKOKU_POSTGRES_DATABASE}
5048
username = ${?DAIKOKU_POSTGRES_USERNAME}
5149
password = ${?DAIKOKU_POSTGRES_PASSWORD}
5250
port = ${?DAIKOKU_POSTGRES_PORT}
53-
storage = ${?DAIKOKU_STORAGE}
51+
poolSize = ${?DAIKOKU_POSTGRES_POOLSIZE}
52+
enabled = ${?DAIKOKU_POSTGRES_SSL_ENABLED}
53+
mode = ${?DAIKOKU_POSTGRES_SSL_MODE}
54+
trusted-cert-path = ${?DAIKOKU_POSTGRES_SSL_TRUSTED_CERT_PATH}
55+
trusted-cert = ${?DAIKOKU_POSTGRES_SSL_TRUSTED_CERT}
56+
client-cert-path = ${?DAIKOKU_POSTGRES_SSL_CLIENT_CERT_PATH}
57+
client-cert = ${?DAIKOKU_POSTGRES_SSL_CLIENT_CERT}
58+
trust-all = ${?DAIKOKU_POSTGRES_SSL_TRUST_ALL}
5459
```

manual/docs/01-getstarted/05-firstrun/run.md

-86
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
import Tabs from '@theme/Tabs';
2+
import TabItem from '@theme/TabItem';
3+
4+
# Run Daikoku
5+
6+
Now you are ready to run Daikoku. You can run the following command with some tweaks depending on the way you want to configure Daikoku. If you want to pass a custom configuration file, use the `-Dconfig.file=/path/to/file.conf` option in the following commands.
7+
8+
:::warning
9+
10+
Daikoku needs a database to run. Before run it, think to start your postgres instance and setup a database with right name (cf. [configuration](../05-firstrun/configfile.md#db-configuration))
11+
12+
:::
13+
14+
<Tabs>
15+
<TabItem value="zip" label="From .zip file" default>
16+
```sh
17+
unzip daikoku-x.x.x.zip
18+
cd daikoku
19+
./bin/daikoku
20+
```
21+
</TabItem>
22+
<TabItem value="jar" label="From .jar file">
23+
For Java 21
24+
25+
```sh
26+
java -jar daikoku.jar
27+
```
28+
</TabItem>
29+
<TabItem value="docker" label="From docker">
30+
```sh
31+
docker run -p "8080:8080" maif/daikoku
32+
```
33+
34+
You can also pass useful args like :
35+
36+
```
37+
docker run -p "8080:8080" daikoku -Dconfig.file=/usr/app/daikoku/conf/daikoku.conf -Dlogger.file=/usr/app/daikoku/conf/daikoku.xml
38+
```
39+
40+
If you want to provide your own config file, you can read [the documentation about config files](../05-firstrun/configfile.md).
41+
42+
You can also provide some ENV variable using the `--env` flag to customize your Daikoku instance.
43+
44+
The list of possible env variables is available [here](../05-firstrun/env.md).
45+
46+
You can use a volume to provide configuration like :
47+
48+
```sh
49+
docker run -p "8080:8080" -v "$(pwd):/usr/app/daikoku/conf" maif/daikoku
50+
```
51+
52+
You can also use a volume if you choose to use exports files :
53+
54+
```sh
55+
docker run -p "8080:8080" -v "$(pwd):/usr/app/daikoku/imports" maif/daikoku -Ddaikoku.init.data.from=/usr/app/daikoku/imports/export.ndjson
56+
```
57+
</TabItem>
58+
</Tabs>
59+
60+
## Run examples
61+
62+
```sh
63+
$ java \
64+
-Xms2G \
65+
-Xmx8G \
66+
-Dhttp.port=8080 \
67+
-Ddaikoku.init.data.from=/home/user/daikoku.ndjson \
68+
-Dconfig.file=/home/user/daikoku.conf \
69+
-jar ./daikoku.jar
70+
71+
[info] play.api.Play - Application started (Prod)
72+
[warn] daikokuEnv - Main dataStore seems to be empty, importing from /home/user/daikoku.conf ...
73+
[warn] daikokuEnv - Importing from: /home/user/daikoku.ndjson
74+
[info] p.c.s.AkkaHttpServer - Listening for HTTP on /0:0:0:0:0:0:0:0:8080
75+
```
76+
77+
If you choose to start Daikoku without importing existing data, Daikoku will create a new admin user and print the login details in the log.
78+
79+
```sh
80+
$ java \
81+
-Xms2G \
82+
-Xmx8G \
83+
-Dhttp.port=8080 \
84+
-jar daikoku.jar
85+
86+
[info] play.api.Play - Application started (Prod)
87+
[warn] DaikokuEnv - Main dataStore seems to be empty, generating initial data ...
88+
[info] p.c.s.AkkaHttpServer - Listening for HTTP on /0.0.0.0:8080
89+
[warn] DaikokuEnv -
90+
[warn] DaikokuEnv - You can log in with admin@daikoku.io / wr4pHmVRArCGhHoteMfwqV6UuvQh6J2z
91+
[warn] DaikokuEnv -
92+
[warn] DaikokuEnv - Please avoid using the default tenant for anything else than configuring Daikoku
93+
[warn] DaikokuEnv -
94+
95+
```

manual/docs/02-usages/07-adminusage/4-importexport.md

+6-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,12 @@ If you want to restore an export, Go to `settings (avatar icon) / Organizations
1616

1717
## Database migration
1818

19-
Since v1.1.1 Daikoku support postgresql database. If you want to migrate you mongoDB to postgresql, it's dead simple like :
19+
Since v1.1.1 Daikoku support postgresql database. If you want to migrate you mongoDB to postgresql, it's dead simple like the following instructions.
20+
21+
:::danger
22+
Since **v17.0.0**, Daikoku do not support mongoDB anymore. To run database migration, you need to be in **16.3.6 max**.
23+
:::
24+
2025
1. add your postgresql access in daikoku configuration
2126
2. keep mongo as daikoku.storage configuration
2227
3. run the migration

0 commit comments

Comments
 (0)