Clever-Cloud
Now you want to use Otoroshi on Clever Cloud. Otoroshi has been designed and created to run on Clever Cloud and a lot of choices were made because of how Clever Cloud works.
Create an Otoroshi instance on CleverCloud
If you want to customize the configuration use env. variables, you can use the example provided below
Create a new CleverCloud app based on a clevercloud git repo (not empty) or a github project of your own (not empty).
Then choose what kind of app your want to create, for Otoroshi, choose Java + Jar
Next, set up choose instance size and auto-scalling. Otoroshi can run on small instances, especially if you just want to test it.
Finally, choose a name for your app
Now you just need to customize environnment variables
at this point, you can also add other env. variables to configure Otoroshi like in the example provided below
You can also use expert mode :
Now, your app is ready, don’t forget to add a custom domains name on the CleverCloud app matching the Otoroshi app domain.
Example of CleverCloud env. variables
You can add more env variables to customize your Otoroshi instance like the following. Use the expert mode to copy/paste all the values in one shot. If you want an real datastore, create a redis addon on clevercloud, link it to your otoroshi app and change the APP_STORAGE
variable to redis
https://otoroshi-699e0604df57b985.cleverapps.io
You can connect on your instance with the following credentials
699e0604df57b985@otoroshi.io / 42deb17058edee042fb756a36eed9c4d
You can use your instance api at
https://otoroshi-api-699e0604df57b985.cleverapps.io
with the following authorization header
Authorization: Basic NmY3MzU3MTNmY2ZiZGQxOWQ1MjZhOTJhYTNiZjZlMjo4ZGUwMzc2NDc1OThkN2FlMDFhMTY2MTBkZjM2MzVhYg==
ADMIN_API_CLIENT_ID=6f735713fcfbdd19d526a92aa3bf6e2
ADMIN_API_CLIENT_SECRET=8de037647598d7ae01a16610df3635ab
ADMIN_API_GROUP=f94f86ab6d2928075ece90242dc82e
ADMIN_API_SERVICE_ID=54b7714d23bf05c5c6ee0271e29d01e2
CLAIM_SHAREDKEY=4868c331e1c1986a80522a158e6b3b6d
OTOROSHI_INITIAL_ADMIN_LOGIN=699e0604df57b985@otoroshi.io
OTOROSHI_INITIAL_ADMIN_PASSWORD=42deb17058edee042fb756a36eed9c4d
OTOROSHI_SECRET=1da73b5e65405a06675874a28b3a795
PLAY_CRYPTO_SECRET=218e18b395b92f8ecbd9a281dcb406c5
SESSION_NAME=oto-session-bbb7a1d1
APP_DOMAIN=cleverapps.io
APP_BACKOFFICE_SUBDOMAIN=otoroshi-699e0604df57b985
APP_PRIVATEAPPS_SUBDOMAIN=otoroshi-papps-699e0604df57b985
ADMIN_API_TARGET_SUBDOMAIN=otoroshi-api-int-699e0604df57b985
ADMIN_API_EXPOSED_SUBDOMAIN=otoroshi-api-699e0604df57b985
APP_ENV=prod
APP_STORAGE=inmemory
APP_ROOT_SCHEME=https
CC_OTO_VERSION=curl https://updates.otoroshi.io/api/versions/latest | jq -r '.version_raw';
CC_PRE_BUILD_HOOK=curl -L -o otoroshi.jar 'https://github.com/MAIF/otoroshi/releases/download/v16.22.0/otoroshi.jar'
CC_JAR_PATH=./otoroshi.jar
CC_JAVA_VERSION=11
PORT=8080
SESSION_DOMAIN=.cleverapps.io
SESSION_MAX_AGE=604800000
SESSION_SECURE_ONLY=true
USER_AGENT=otoroshi-699e0604df57b985
MAX_EVENTS_SIZE=1
WEBHOOK_SIZE=100
APP_BACKOFFICE_SESSION_EXP=86400000
APP_PRIVATEAPPS_SESSION_EXP=86400000
ENABLE_METRICS=true
OTOROSHI_ANALYTICS_PRESSURE_ENABLED=true
USE_CACHE=true