Hi all,
I don’t see clear documentation on getting the API setup as far as the docker implementation is concerned and am having trouble connecting. So here’s what I’ve done, and I could still use some help. Here’s my setup – using the latest 2023.9.9 version:
Using a docker compose file on ubuntu. This is my .env file (any asterisk is information I’ve removed):
# docker-compose supports environment variable interpolation/substitution in compose configuration file
# (more info: https://docs.docker.com/compose/environment-variables)
########################################################################################################################
# General settings
DOMAIN=****.com
VERSION=2023.9.9
HTTP_SSL_TERMINATED=true
########################################################################################################################
# Database connection
DB_DSN=postgres://**:**@db:5432/corteza?sslmode=disable
########################################################################################################################
# Server settings
# Running all-in-one and serving web applications directly from server container
HTTP_WEBAPP_ENABLED=true
HTTP_API_ENABLED=true
HTTP_API_BASE_URL=/api
# Disabled, we do not need detailed persistent logging of actions in local env
ACTIONLOG_ENABLED=false
I’m hoping to the web server and api server run on the same docker container. The web server looks great. I was able to create an Auth Client, that uses client_credentials and has access to the Corteza API Server on behalf of user. For simplicity sake, and for now (will change later), i’m just impersonating my user, which is a super admin.
I’m able to login with the endpoint https:///auth/oauth2/token using my client_id and client_secret. Then when using the access_token, when I try to hit any api endpoint, I get a 404. The simple endpoint I’m trying to hit is https:///api/system/auth/clients – although I’ve tried many from the /api/docs documentation. All of them return 404. Which tells me maybe the API server isn’t running or I’ve missed something when setting up? What am I missing. Is there clearer docs on how to get the API Server setup? Thanks in advance for the help!