Closed AbhiPawar5 closed 1 week ago
Hi @AbhiPawar5
By default we try to log to the Opik Hosted environment, in order to point to the local environment you will need to set: export OPIK_URL_OVERRIDE="http://localhost:5173/api"
or if you are in python:
import os
os.environ["OPIK_URL_OVERRIDE"] = "http://localhost:5173/api:
On Monday we are going to release a new opik.login
method that will mean you simply need to call opik.login(local=True)
and everything will be set for you and saved in a configuration file.
Thank you, @jverre. To be honest and direct, the documentation and developer experience is very poor!
How do I start the Opik server again? I had stopped the container, it doesn't seem to restart by itself.
I appreciate the honest feedback ! We do indeed have some challenges on local deployments, they are pretty hard to set up and manage.
We are moving to a much simpler docker compose set-up which should drastically simplify the experience. This combined with the new login method will make it much simpler to get started. I'll also make some updates to the docs based on your feedback
@CRThaze can you help with instructions on how to restart the service ?
Hi @AbhiPawar5, I wanted to follow up on this as we have just released a number of improvements to make it easier to run Opik locally.
New local deployment option:
We have moved to a docker compose
based deployment that greatly simplifies the setup, simply clone the repo, navigate to deployments/docker-compose
and run docker compose up --detach
. I have also updated the self-hosting to docs with more information about starting, stoping and upgrading Opik when using this deployment approach. You can learn more about it here: https://www.comet.com/docs/opik/self-host/local_deployment.
Simplified the setup of the SDK:
We have introduced a new opik configure
CLI command and opik.configure(use_local=False)
method that will create a Opik SDK configuration file, no more environment variables to manage ! You simply need to run this command once and once you have finished the setup process ( takes less than 30 seconds), the Opik SDK will be fully configured. We have updated many of the examples in the docs to use this method and will continue to improve the behavior here.
For now I'm going to close this ticket but happy to re-open it if you are running into issues
Willingness to contribute
No. I can't contribute a fix for this bug at this time.
What component(s) are affected?
Opik version
Describe the problem
How do I use the Opik server locally? I'm following the steps mentioned here - https://www.comet.com/docs/opik/tracing/log_traces
but my API go to comet servers, why?
Reproduction steps