> For the complete documentation index, see [llms.txt](https://ibm-developer.gitbook.io/get-your-java-microservice-up-and-running/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://ibm-developer.gitbook.io/get-your-java-microservice-up-and-running/setup-local-and-ibm-cloud-environment/5-setup-all.md).

# Setup for local development and cloud deployment

### Remember! We use two terminal sessions

> * **The first terminal session** is for the developer focused exercises 1 and 2.
> * **The second terminal session** is for exercise 3 deploy the Microservice to Kubernetes, here you will work in a preconfigured Container image.

![](https://1786616095-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MG3nxFYptsAGAKhoxq6%2Fsync%2F27789961c1bac70a7a2688b5228c23adaa429efc.gif?generation=1598884074490958\&alt=media)

## Step 1: Code locally - Open a terminal session and run these commands

Download the project locally to work in the Developer labs locally.

```
git clone https://github.com/IBM/cloud-native-starter
cd cloud-native-starter
ROOT_FOLDER=$(pwd)
```

The local project is needed for Java development labs 2 and 3, because you can't use Docker in the 'cns-workshop-tools' Docker image. (for more see this [article](https://suedbroecker.net/2019/08/27/definition-of-a-dockerfile-to-use-bash-scripts-on-a-windows-10-machine-for-our-cloud-native-starter-workshop/) )

### Step 2: Open new terminal session and run these commands

* Start the container

```bash
docker run -it --privileged --rm quay.io/tsuedbroecker/cns-workshop-tools:buildah-v1
```

### Step 3: After the container has been started, run these commands inside your running Docker image to get the lastest version of the workshop

```bash
cd /
git clone https://github.com/IBM/cloud-native-starter.git
cd cloud-native-starter
ROOT_FOLDER=$(pwd)
```

### Step 4: Verfiy the tool prerequisites on for the workshop

```bash
chmod u+x iks-scripts/*.sh
chmod u+x scripts/*.sh
./iks-scripts/check-prerequisites.sh
```

***
