Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

localai-webui example missing .env file #1066

Closed
jamesbraza opened this issue Sep 15, 2023 · 3 comments · Fixed by #1124
Closed

localai-webui example missing .env file #1066

jamesbraza opened this issue Sep 15, 2023 · 3 comments · Fixed by #1124
Assignees
Labels
bug Something isn't working

Comments

@jamesbraza
Copy link
Contributor

Going to examples/localai-webui and running it per the examples/localai-webui/README.md:

> docker-compose up --pull always
Failed to load /Users/user/code/repo/localai/examples/localai-webui/.env: open /Users/user/code/repo/localai/examples/localai-webui/.env: no such file or directory

I think a placeholder .env file needs to be added to this folder.

@jamesbraza jamesbraza added the bug Something isn't working label Sep 15, 2023
@jamesbraza
Copy link
Contributor Author

The examples/slack-bot/ has a .env.example that its README instructs to cp to a .env file. I think something like this should be added for localai-webui

@localai-bot
Copy link
Contributor

⚠️⚠️⚠️⚠️⚠️

Hi! I'm a bot running with LocalAI ( a crazy experiment of @mudler ) - please beware that I might hallucinate sometimes!

but.... I can also be funny or helpful 😸 and I can provide generally speaking good tips or places where to look after in the documentation or in the code based on what you wrote in the issue.

Don't engage in conversation with me,
I don't support (yet) replying!

⚠️⚠️⚠️⚠️⚠️

Yes, that is correct. The docker-compose.yaml file in the examples/localai-webui directory assumes that there is a .env file present with certain environment variables defined. You can create a new .env file and set the appropriate variables for your setup. Here's an example of what the .env file might look like:

# Set number of threads.
THREADS=2
# Specify a different bind address (defaults to ":8080")
ADDRESS=127.0.0.1:8080

Make sure to update the ADDRESS variable with an appropriate IP address or FQDN for your setup. Once you've created the .env file, you can run docker-compose up --pull always again and it should work as expected.

Sources:

@jamesbraza
Copy link
Contributor Author

Thanks @localai-bot. I think the repo should have an .env file already present, users shouldn't have to create one after the code crashes

mudler pushed a commit that referenced this issue Oct 2, 2023
Closes #1066 and
#1065

Standardizes all `examples/`:
- Models in one place (other than `rwkv`, which was one-offy)
- Env files as `.env.example` with `cp`
    - Also standardizes comments and links docs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants