2025/06/26
 
26 Jun, 2025

Develop Locally, Test Remotely: Choreo’s ‘Teleport’ for Dependencies

When building complex, interdependent projects, local testing and debugging often become challenging. This is a common situation for most internal developer platforms and large-scale deployments. Replicating a deployed environment locally is inherently complex, especially when the code depends on external services or specific platform integrations. While deploying changes to a remote environment for testing is an option, it often introduces delays, slowing down iteration cycles and impacting developer productivity.

To address these common development hurdles, Choreo is introducing a new capability that bridges your local development environment with your deployed Choreo project. This feature streamlines local development and testing for components that depend on Choreo connections. Using the Choreo CLI or the VS Code extension, developers can create a secure, connected environment that enables real-time testing and validation.


Figure 1: Concept diagram

This connected environment works by creating a secure tunnel, allowing you to connect directly to your deployed services in the Choreo environment. This is especially beneficial for accessing private services that are not publicly accessible.

Furthermore, if you're leveraging Choreo connections to manage your component's dependencies, this connected environment enhances your workflow even more. It automatically injects the configuration environment variables of your Choreo connections into the subshell, streamlining your setup and ensuring these services are fully accessible to your local component.

Key advantages of this connected environment:

  • Seamless Access to Dependencies: Your local components automatically receive all necessary connection details for Choreo services, third-party integrations, and databases, eliminating manual setup.
  • Early Integration Testing: Validate how your local component interacts with Choreo services running in your development environment, even before committing code. This ensures you're testing against an environment that closely mirrors your deployment.
  • Consistent and Reliable Testing: Achieve consistent test results, whether you're running locally or in your CI/CD pipeline, increasing confidence in your changes and deployments.

How to Use It?

  1. Prerequisites:
    a. Have dependent components deployed in Choreo.
    b. Have the components connected via Choreo connections.

  2. Install the Choreo CLI and run the following command:
    This command launches a specialized subshell within your terminal, directly connected to your remote deployed Choreo environment. From this subshell, you can directly test your internal services, even by running commands like curl to their private URLs. If you're using Choreo connections to link your components and their dependencies, the subshell automatically injects the corresponding configuration environment variables into your local environment, streamlining your application's setup for accessing those connected services.

  3. With this subshell active, start your application using its usual local command (e.g., `npm start`, `python app.py`,`java -jar app.jar`). 

    Once running within the subshell, your local application can access its remote dependencies. It automatically picks up connection details from environment variables (provided by Choreo connections) or from URLs specified in your code. This enables a direct connection to your Choreo project for local development.

  4. For advanced options and flags, run `choreo connect --help`, or refer to Choreo documentation for comprehensive guidance.

Extending to CI Environments

The ‘choreo connect’ command can also be used within your continuous integration (CI) workflows. To run tests in your CI environment while connected to your Choreo project, authenticate using a Choreo personal access token. This allows your test suites to run against real dependencies, improving test accuracy and reliability.

Debugging with VS Code

This connected environment capability also enhances local debugging workflows. Using the Choreo VS Code Extension, you can launch and debug your applications while connected to your Choreo project. For detailed instructions on configuring your VS Code launch settings, please refer to the Choreo documentation.

Get Started Today

This new feature is designed to streamline and accelerate your local development workflow with Choreo. We encourage you to give it a try. If you have any questions, feedback, or need help getting started, our community is here to support you. Join us on Discord to connect with our team and other developers.

English