Skip to content

Commit

Permalink
chore: linux natively (#455)
Browse files Browse the repository at this point in the history
Co-authored-by: Animesh Pathak <53110238+Sonichigo@users.noreply.github.com>
Co-authored-by: Neha Gupta <gneha21@yahoo.in>
  • Loading branch information
3 people authored and actions-user committed Sep 29, 2024
1 parent a7f98f4 commit a8f529c
Show file tree
Hide file tree
Showing 4 changed files with 112 additions and 109 deletions.
107 changes: 0 additions & 107 deletions versioned_docs/version-2.0.0/concepts/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,113 +93,6 @@ alias keploy="docker run --name keploy-v2 -p 16789:16789 --network keploy-networ

</details>

<details>

<summary>Running Keploy Natively on MacOS by setting up a linux env</summary>

### Downloading and running Keploy in Native using Debian on MacOS

1. Open the terminal Session.
2. Run the following command

```bash
limactl show-ssh --format=config debian-12 & add it to its ssh config
```

3. Open a remote window on your code editor
4. Click on connect to host
5. Now select the configured SSH as "lima-debian"
6. Once you are in the terminal run the following commands to go into your directory

```bash
cd /Users
```

```bash
cd /{Username}
```

7. Run the following command to install Keploy

```bash
curl --silent --location "https://github.com/keploy/keploy/releases/latest/download/keploy_linux_arm64.tar.gz" | tar xz --overwrite -C /tmp
sudo mkdir -p /usr/local/bin && sudo mv /tmp/keploy /usr/local/bin/keploy
```

8. Run the following command to install Zsh

```bash
sudo apt-get -y install zsh
```

**Why?** : zsh (Z Shell) is an advanced shell that offers enhanced features compared to the default bash shell. It provides better autocompletion, advanced globbing, improved history management, and more customization options.

9. Install Git

```bash
sudo apt-get -y install git
```

10. Install 'Oh-my-zsh'

```bash
sh -c "$(wget https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh -O -)"
```

**Why?** : oh-my-zsh is a framework for managing your zsh configuration. It comes with a collection of plugins, themes, and helpful features that enhance the zsh experience.

11. Commands to Install docker

```bash
sudo apt-get -y update
```

```bash
sudo apt-get -y install ca-certificates curl
```

```bash
sudo install -m 0755 -d /etc/apt/keyrings
```

```bash
sudo curl -fsSL https://download.docker.com/linux/debian/gpg -o /etc/apt/keyrings/docker.asc
```

```bash
sudo chmod a+r /etc/apt/keyrings/docker.asc
```

```bash
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/debian \
$(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
```

```bash
sudo apt-get -y update
```

```bash
sudo apt-get -y update
```

```bash
sudo apt-get -y install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
```

12. Add docker to sudoers

```bash
sudo groupadd docker
```

```bash
sudo gpasswd -a $USER docker
```

</details>
<details>
<summary>Downloading and running Keploy in Native</summary>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Linux:

| Operating System | Without Docker | Docker Installation | Prerequisites |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <img src="https://www.pngplay.com/wp-content/uploads/3/Apple-Logo-Transparent-Images.png" width="15" height="15" alt="MacOS" /> **MacOS** | <img src="https://upload.wikimedia.org/wikipedia/en/b/ba/Red_x.svg" width="20" height="20" alt="Not Supported" /> | <img src="https://upload.wikimedia.org/wikipedia/commons/e/e5/Green_tick_pointed.svg" width="20" height="20" alt="Supported" /> | Docker Desktop version must be 4.25.2 or above |
| <img src="https://www.pngplay.com/wp-content/uploads/3/Apple-Logo-Transparent-Images.png" width="15" height="15" alt="MacOS" /> **MacOS** | <img src="https://upload.wikimedia.org/wikipedia/en/b/ba/Red_x.svg" width="20" height="20" alt="Not Supported" /> | <img src="https://upload.wikimedia.org/wikipedia/commons/e/e5/Green_tick_pointed.svg" width="20" height="20" alt="Supported" /> | - Docker Desktop version must be 4.25.2 or above<br/> - For running Keploy on MacOS natively, refer to [Guide](/keploy-explained/mac-linux.md) |
| <img src="https://upload.wikimedia.org/wikipedia/commons/5/5f/Windows_logo_-_2012.svg" width="15" height="15" alt="Windows" /> **Windows** | <img src="https://upload.wikimedia.org/wikipedia/commons/e/e5/Green_tick_pointed.svg" width="20" height="20" alt="Supported" /> | <img src="https://upload.wikimedia.org/wikipedia/commons/e/e5/Green_tick_pointed.svg" width="20" height="20" alt="Supported" /> | - Use [WSL](https://learn.microsoft.com/en-us/windows/wsl/install#install-wsl-command) `wsl --install` <br/> - Windows 10 version 2004 and higher (Build 19041 and higher) or Windows 11 |
| <img src="https://th.bing.com/th/id/R.7802b52b7916c00014450891496fe04a?rik=r8GZM4o2Ch1tHQ&riu=http%3a%2f%2f1000logos.net%2fwp-content%2fuploads%2f2017%2f03%2fLINUX-LOGO.png&ehk=5m0lBvAd%2bzhvGg%2fu4i3%2f4EEHhF4N0PuzR%2fBmC1lFzfw%3d&risl=&pid=ImgRaw&r=0" width="10" height="10" alt="Linux" /> **Linux** | <img src="https://upload.wikimedia.org/wikipedia/commons/e/e5/Green_tick_pointed.svg" width="20" height="20" alt="Supported" /> | <img src="https://upload.wikimedia.org/wikipedia/commons/e/e5/Green_tick_pointed.svg" width="20" height="20" alt="Supported" /> | Linux kernel 5.15 or higher |

Expand Down
109 changes: 109 additions & 0 deletions versioned_docs/version-2.0.0/keploy-explained/mac-linux.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
---
id: mac-linux
title: "Running Keploy Natively on MacOS by setting up a linux env"
sidebar_label: Keploy on MacOS native
---

# Running Keploy Natively on MacOS by setting up a linux env

### Downloading and running Keploy in Native using Debian on MacOS

1. Open the terminal Session.
2. Run the following command

```bash
limactl show-ssh --format=config debian-12 & add it to its ssh config
```

3. Open a remote window on your code editor
4. Click on connect to host
5. Now select the configured SSH as "lima-debian"
6. Once you are in the terminal run the following commands to go into your directory

```bash
cd /Users
```

```bash
cd /{Username}
```

7. Run the following command to install Keploy

```bash
curl --silent --location "https://github.com/keploy/keploy/releases/latest/download/keploy_linux_arm64.tar.gz" | tar xz --overwrite -C /tmp
sudo mkdir -p /usr/local/bin && sudo mv /tmp/keploy /usr/local/bin/keploy
```

8. Run the following command to install Zsh

```bash
sudo apt-get -y install zsh
```

**Why?** : zsh (Z Shell) is an advanced shell that offers enhanced features compared to the default bash shell. It provides better autocompletion, advanced globbing, improved history management, and more customization options.

9. Install Git

```bash
sudo apt-get -y install git
```

10. Install 'Oh-my-zsh'

```bash
sh -c "$(wget https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh -O -)"
```

**Why?** : oh-my-zsh is a framework for managing your zsh configuration. It comes with a collection of plugins, themes, and helpful features that enhance the zsh experience.

11. Commands to Install docker

```bash
sudo apt-get -y update
```

```bash
sudo apt-get -y install ca-certificates curl
```

```bash
sudo install -m 0755 -d /etc/apt/keyrings
```

```bash
sudo curl -fsSL https://download.docker.com/linux/debian/gpg -o /etc/apt/keyrings/docker.asc
```

```bash
sudo chmod a+r /etc/apt/keyrings/docker.asc
```

```bash
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/debian \
$(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
```

```bash
sudo apt-get -y update
```

```bash
sudo apt-get -y update
```

```bash
sudo apt-get -y install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
```

12. Add docker to sudoers

```bash
sudo groupadd docker
```

```bash
sudo gpasswd -a $USER docker
```
3 changes: 2 additions & 1 deletion versioned_sidebars/version-2.0.0-sidebars.json
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,8 @@
"keploy-explained/contribution-guide",
"keploy-explained/docs-dev-guide",
"keploy-explained/debugger-guide",
"keploy-explained/testing-guide"
"keploy-explained/testing-guide",
"keploy-explained/mac-linux"
]
}
]
Expand Down

0 comments on commit a8f529c

Please sign in to comment.