Welcome to the devcontainer-generator project! This tool helps you automatically generate devcontainer.json
files for your development environments based on the structure and contents of a given GitHub repository.
devcontainer-generator
├── tests.ipynb
├── requirements.txt
├── schemas
│ └── devContainer.base.schema.json
├── README.md
├── main.py
└── data
└── devcontainers.db
devcontainer.json
file.devcontainer.json
files.To run this project in Daytona, you'll need to have Daytona installed. Follow these steps to set up the project:
Install Daytona:
(curl -L https://download.daytona.io/daytona/install.sh | sudo bash) && daytona server stop && daytona server -y && daytona
Create new project and run IDE:
daytona create https://github.com/nkkko/devcontainer-generator --code
Set up environment variables:
Create a .env
file in the project's root directory and add the following environment variables:
AZURE_OPENAI_ENDPOINT=your_azure_openai_endpoint
AZURE_OPENAI_API_KEY=your_azure_openai_api_key
AZURE_OPENAI_API_VERSION=your_azure_openai_api_version
MODEL=your_model_name
GITHUB_TOKEN=your_github_token
Run the main.py
script to start the FastHTML app and generate devcontainer.json
files. Here's how you can do it:
python main.py
Instructions:
http://localhost:8000
.devcontainer.json
file.devcontainer.json
will be displayed and can be copied to your clipboard.Ensure the following environment variables are set in your .env
file:
AZURE_OPENAI_ENDPOINT=your_azure_openai_endpoint
AZURE_OPENAI_API_KEY=your_azure_openai_api_key
AZURE_OPENAI_API_VERSION=your_azure_openai_api_version
MODEL=your_model_name
GITHUB_TOKEN=your_github_token
The project uses an SQLite database to store the generated devcontainer.json
files and their embeddings. The database is located in the data
directory.
The JSON schema for the devcontainer.json
file is located in schemas/devContainer.base.schema.json
.
Steps to Set Up Daytona Workspace
Create Daytona Workspace:
daytona create https://github.com/nkkko/devcontainer-generator
Select Preferred IDE:
daytona ide
Open the Workspace:
daytona code
We welcome contributions! Please read our CONTRIBUTING.md file for guidelines on how to contribute to this project.
This project is licensed under the MIT License. See the LICENSE file for more details.
Thank you for using devcontainer-generator! If you have any questions or issues, feel free to open an issue on GitHub.