Giter VIP home page Giter VIP logo

autogen-studio-dockerfile's Introduction

Autogen Studio Docker Image

This repository contains a dockerfile which can be used to build a docker image for the Autogen Studio. The docker image can be used to run the Autogen Studio in a docker container.

Building the docker image

To build the docker image, run the following command in the root of this repository:

docker build -t autogenstudio .

Running the docker image

To run the docker image, run the following command:

docker run -it --rm -p 8081:8081  -e "OPENAI_API_KEY=your_openai_api_key" autogenstudio

The Autogen Studio will be available at http://localhost:8081.

autogen-studio-dockerfile's People

Contributors

ricktonoli avatar waywardhayward avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

autogen-studio-dockerfile's Issues

Can't run image with OAI key insertion through terminal: Error: No such option: -e -

when trying to run the built image with "docker run -it --rm -p 8081:8081 autogenstudio -e "OPENAI_API_KEY='yourkey" get the error:

Error: No such option: -e
(autogenstudio) #:~/lrepos/autogen_docker$ autogenstudio ui --help
Usage: autogenstudio ui [OPTIONS]

Launch the AutoGen Studio UI CLI .Pass in parameters host, port, workers,
and reload to override the default values.

Options:
--host TEXT [default: 127.0.0.1]
--port INTEGER [default: 8081]
--workers INTEGER [default: 1]
--reload
--docs / --no-docs [default: no-docs]
--help Show this message and exit.

Persisting Data

This is more of an FYI. I couldn't come up with a better way to do this but maybe you can if you do future iterations.

It looks like the database at /usr/local/lib/python3.10/site-packages/autogenstudio/web/database.sqlite is storing the application information.

To be able to persist the data between container instances, i first extract a copy of the file by mounting a volume like such

/home/server/autogen-studio/sample:/usr/local/lib/python3.10/site-packages/autogenstudio/web/sample

I copy the database.sqlite at /usr/local/lib/python3.10/site-packages/autogenstudio/web/database.sqlite to the sample folder from within the container which makes the file available outside of the container.

I destroy the stack/container and run again but use the following mount as my volume

/home/server/autogen-studio/database.sqlite:/usr/local/lib/python3.10/site-packages/autogenstudio/web/database.sqlite

This was the compose file I used.

version: "3"
services:
  autogen-studio:
    image: autogen-studio:latest
    container_name: autogen-studio
    volumes:
      - /home/server/autogen-studio/database.sqlite:/usr/local/lib/python3.10/site-packages/autogenstudio/web/database.sqlite
      #- /home/server/autogen-studio/sample:/usr/local/lib/python3.10/site-packages/autogenstudio/web/sample
    ports:
      - 38081:8081

Thanks for the repo! It helped get me going.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.