Configuration

Twitcher has a configuration file development.ini for local development. Copy and edit this configuration to adapt to your settings.

Service

Edit the configuration to change the service parameters.

The URL of the Twitcher service endpoint:

twitcher.url = http://localhost:8000

Basic Authentication

Twitcher uses basic authentication for client application registration and service registration. Edit username and password in the configuration:

twitcher.username = demo
twitcher.password = demo

OAuth2 Token Generator

Twitcher uses OAuth2 tokens to control OWS service access. You can use several types of tokens.

Random Token

Tokens with UUID strings stored in the local twitcher database.

Edit the configuration file:

twitcher.token.type = random_token

Signed Token

JWT tokens signed with a certificate. You can generate a self-signed certificate for testing with the Makefile:

$ make gencert

Edit the configuration file:

twitcher.token.type = signed_token
twitcher.token.keyfile = key.pem # private key
twitcher.token.certfile = pubkey.pem # public key

Custom Token

JWT tokens using a shared secret. You can generate a UUID secret with:

$ make gensecret

Edit the configuration file:

twitcher.token.type = custom_token
twitcher.token.secret = secret

Keycloak Token

JWT tokens generated by a Keycloak OAuth2 service.

Edit the configuration file:

twitcher.token.type = keycloak_token

You need to copy the public key of your Keycloak realm to the configuration (see screenshot):

keycloak.token.secret = secret
_images/keycloak-realm-public-key.png