Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add environment variables troubleshooting info #260

Merged
merged 2 commits into from
Jul 9, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 33 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,39 @@ io.onConnection(channel => {

## Troubleshooting

Geckos does not run on `http://localhost:PORT/`? Try `http://127.0.0.1:PORT/` instead.
- Geckos does not run on `http://localhost:PORT/`? Try `http://127.0.0.1:PORT/` instead.
- If server listener is listening but never establishes a connection, that might be due to your machine not exposing OPENSSL environment variables (see https://github.com/geckosio/geckos.io/pull/260). To add them try the following:

<details>
<summary>Exposing OPENSSL environment variables</summary>

1. Find the path to OpenSSL:

```bash
brew --prefix openssl
```

2. Set the environment variables. You can set the environment variables in your shell by adding the following lines to your shell profile file (usually ~/.bash_profile, ~/.bashrc, or ~/.zshrc for Zsh):

```bash
export OPENSSL_ROOT_DIR=/usr/local/opt/[email protected]
export OPENSSL_CRYPTO_LIBRARY=/usr/local/opt/[email protected]/lib
export OPENSSL_INCLUDE_DIR=/usr/local/opt/[email protected]/include
```

Replace `/usr/local/opt/[email protected]` with the path you got from the second step. Then, save the file and restart your terminal for the changes to take effect.

3. Check that the environment variables are set (maybe you'll need to restart your terminal):

```bash
echo $OPENSSL_ROOT_DIR
echo $OPENSSL_CRYPTO_LIBRARY
echo $OPENSSL_INCLUDE_DIR
```

4. Done ✅

</details>

## Cheatsheet

Expand Down