> For the complete documentation index, see [llms.txt](https://docs.terrakube.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.terrakube.io/getting-started/development/github-codespaces.md).

# GitHub Codespaces

This page contains the configuration for a development container using GitHub Codespaces that provides a consistent environment for working with Terrakube.

The devcontainer includes all the necessary tools and dependencies to develop both the Java backend, TypeScript frontend components and includes terraform CLI.

### Features

* Java 25 (Liberica)
* Maven 3.9.9
* Node.js 24.x with Yarn
* VS Code extensions for Java, JavaScript/TypeScript

### Prerequisites

* GitHub Account

### **Prepare project**

The first step is to create a GitHub fork to work with Terrakube

<figure><img src="/files/iGpRFLcly0bEKeeWomRx" alt=""><figcaption></figcaption></figure>

Once you have created a fork you need to create a new branch to work for any new Terrakube feature

<figure><img src="/files/bjruYDSvntKBs7gYKwGj" alt=""><figcaption></figcaption></figure>

Open a new GitHub workspace using "new with options"

<figure><img src="/files/mDLO0xz8QlRh8TQQbVw3" alt=""><figcaption></figcaption></figure>

Select a 4 CPU configuration like the following.

<figure><img src="/files/H6mQZvTx1slVQKy0O3AU" alt=""><figcaption></figcaption></figure>

Dev container setup will take a couple of minutes.

<figure><img src="/files/eG0msHDJ05HGUa9oL4Av" alt=""><figcaption></figcaption></figure>

Once the environment setup is completed, you will see the following message

<figure><img src="/files/ezkKmOAHbl1ggHz7bD8d" alt=""><figcaption></figcaption></figure>

Now we can run the new development environment

<figure><img src="/files/TibfTS6f1CN1WfxWqkeQ" alt=""><figcaption></figcaption></figure>

You need to accept using the Java "Standard Mode".

<figure><img src="/files/jTCwNdzUVqAmanlRY0Yi" alt=""><figcaption></figcaption></figure>

The dev container will download all the maven dependencies, this could take a couple of minutes

<figure><img src="/files/PrZ8Jzbt8m74F9t8mYDL" alt=""><figcaption></figcaption></figure>

Once all dependencies are downloaded, you can see the four component running like the following

<figure><img src="/files/gpbDI0IGCrcNjWML6mtA" alt=""><figcaption></figcaption></figure>

If not you can simply start the ui, api, registry and executor one by one using the following menu

<figure><img src="/files/2SLU0LxF5NxVnvbBcphd" alt=""><figcaption></figcaption></figure>

After we have the components running, we need to change the port configuration, we need to make sure DEX, the api, registry and ui are using public ports.

<figure><img src="/files/nPKuqMWuSIOZXSfpJdP6" alt=""><figcaption></figcaption></figure>

Example:

<figure><img src="/files/kTynfgugU55MZPV1gex2" alt=""><figcaption></figcaption></figure>

In the end it should look like this using public ports:

<figure><img src="/files/BZ7tUkGkZUPKi14noCGv" alt=""><figcaption></figcaption></figure>

The development environment automatically creates "DEVCONTAINER.md" that contains all the URL for each component.

<figure><img src="/files/rKomD4s5PcsBACqpewtS" alt=""><figcaption></figcaption></figure>

You will need to visit the URL for dex, ui, api and registry in order to accept that we need to use a public port for our environment.

<figure><img src="/files/Kb6jWTBc928COzcWgJRD" alt=""><figcaption></figcaption></figure>

You will see a message like this and click "continue"

<figure><img src="/files/M8a9Ft2mr66jhFU0ZEob" alt=""><figcaption></figcaption></figure>

Once you click continue

<figure><img src="/files/kFhHqerek73TlpcsL29j" alt=""><figcaption></figcaption></figure>

You need to do the same for the other components: api, registry, executor and dex

<figure><img src="/files/fAiVnUB1cV2SyGFHODAf" alt=""><figcaption></figcaption></figure>

Now you can go back to the UI and click "Sign in"

<figure><img src="/files/erod5NYQIvDOLKaOOxSH" alt=""><figcaption></figcaption></figure>

This will redirect you to dex where you can use "<admin@example.com>" and "admin" to complete the login.

<figure><img src="/files/UE4u2zycSRtYyUIrF3fF" alt=""><figcaption></figcaption></figure>

Grant DEX access

<figure><img src="/files/wkZVWY0dks85WbIDU4SW" alt=""><figcaption></figcaption></figure>

Now you can start testing the development environment and do any required changes

<figure><img src="/files/7N51sDJ0Wc8rgiB442R6" alt=""><figcaption></figcaption></figure>

If you need to update the code for any java component, you can simply click "Stop"

<figure><img src="/files/MUb7W2zmwGOAg7BJtog5" alt=""><figcaption></figcaption></figure>

Start a new instance

<figure><img src="/files/muNkkfFZLtOggpH8Bj79" alt=""><figcaption></figcaption></figure>

Once all the changes are completed, we pick the files an push the changes to our feature branch

<figure><img src="/files/QpauWNgrYldxYU84eFs9" alt=""><figcaption></figcaption></figure>

You can return to GitHub and create a new pull request to the Terrakube main repository

<figure><img src="/files/mO998wdX0hK3UzYc7ztI" alt=""><figcaption></figcaption></figure>

In the end the pull request will look like this.

<figure><img src="/files/GxerNFq4V3dnPSGDDMsz" alt=""><figcaption></figcaption></figure>

Now you have completed your open source contribution to Terrakube 🙂

Finally you can go to GitHub and delete your codespace.

<figure><img src="/files/DWQS4MjhuQVgMv8MjLco" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.terrakube.io/getting-started/development/github-codespaces.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
