Development Environment for genai-stack
Overview
The Development Environment
for the genai-stack
project refers to the setup and configuration required to develop, build, and run the various components of the stack. This documentation covers the possible options and provides examples for each, as well as troubleshooting tips.
What is Development Environment?
According to the genai-stack documentation, the Development Environment is the collection of tools, libraries, and configurations that developers use to write, test, and deploy code. In the context of the genai-stack
, this includes setting up the necessary dependencies, building Docker images, and configuring the development tools.
Why is Development Environment important?
As stated in the Docker documentation, having a consistent development environment is crucial for ensuring that the codebase is easily reproducible and maintainable. In the case of genai-stack
, this means having a clear understanding of how to set up the development environment, build the Docker images, and troubleshoot any issues that may arise.
Setting up the Development Environment
Prerequisites
Before getting started, ensure that you have the following prerequisites installed:
Cloning the Repository
To clone the genai-stack
repository, use the following command:
git clone https://github.com/docker/genai-stack.git
Building the Docker Images
To build the Docker images, navigate to the genai-stack
directory and run the following command:
docker-compose build
Starting the Stack
To start the stack, run the following command:
docker-compose up
Rebuilding the Images
To rebuild the Docker images, run the following command:
docker-compose build --no-cache
Entering Watch Mode
To enter watch mode, use the following command:
docker-compose up --build --detach --no-start
Then, in a separate terminal window, run:
docker-compose exec genai-dev sh -c "yarn watch"
Troubleshooting
For troubleshooting tips, refer to the genai-stack documentation.