This repository contains a collection of sample projects ready to deploy in Choreo, a developer platform for easily taking your work to production. These samples demonstrate various use cases and provide examples for different scenarios.
You can explore the README.md
of each sample in its respective directory to learn more about how to use Choreo for specific use cases.
Follow these steps to get started with these Choreo samples:
- Fork this repository to your GitHub account.
- Follow the instructions provided in the respective sample's README to deploy and test the sample.
If you'd like to contribute to this repository, feel free to submit pull requests. Make sure to refer the pull request template.
If you'd like to add a new sample to this repository, please follow the below steps:
- Create a new directory for the sample.
- Add a
README.md
file to the directory with the following information:- A brief description of the sample.
- Instructions on how to deploy the sample in Choreo.
- Instructions on how to test the sample.
- Add a metadatata file for the sample in the
.samples
directory. The metadata file should be named as<sample-name>.yaml
. The metadata file should contain the following information:name
: Name of the sample.description
: A brief description of the sample.componentType
: Component type of the sample. Examples:service
web-application
webhook
manual-task
scheduled-task
event-handler
test-runner
many
buildPack
: Build pack of the sample. Examples:node
python
java
ballerina
dockerfile
many
wso2-mi
repositoryUrl
: The GitHub repository URL of the sample. https://github.com/wso2/choreo-samples/componentPath
: The path to the component in the repository. This should be the path to the directory that contains the sample.thumbnailPath
: The path to the thumbnail image of the sample. This should be the path to the thumbnail image relative to therepositoryUrl
directory. It is recommended to add the thumbnail to the.samples/icons
directory and refer it here.documentationPath
: The path to the documentation/README.md of the sample. This should be the path to the documentation relative to therepositoryUrl
directory.tags
: Tags for the sample. This should be a list of strings.
If you're adding a Quick Deployable sample, follow these additional steps:
- Ensure the
componentType
is one of the following:
service
web-application
manual-task
scheduled-task
- Ensure the presence of a
Dockerfile
in the root directory of the sample you are going to add. (Make sure you manually build it first)- In the metadata file (
<sample-name>.yaml
) file, ensure theimageVersion
is provided.- Ensure the following additional files are included, depending on the component type:
- For services, include an
endpoints.yaml
file in the/.choreo
directory of the component. (Template)- If the service is a REST service, include an OpenAPI specification YAML file in your sample's directory, and specify its relative path from the sample root in the
schemaFilePath
field inendpoints.yaml
.- When making a change that affect the image of the sample: Bump the
imageVersion
- Submit a pull request to this repository.
This project is licensed under the Apache License.
If you have any questions or need assistance, you can join the Choreo community Discord channel.