Skip to content

Instantly share code, notes, and snippets.

@manishkpr
Forked from sepehr/osx-kong.sh
Created June 12, 2018 01:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save manishkpr/99bfea4348d3269d2f7dd8fee3fb8a66 to your computer and use it in GitHub Desktop.
Save manishkpr/99bfea4348d3269d2f7dd8fee3fb8a66 to your computer and use it in GitHub Desktop.
OSX: Kong Installation
#!/bin/bash
#
# The homebrew formula of kong has a lot of version incompatibilities. So
# we install kong directly from Luarocks.
#
# Kong only works with Cassandra 2.1.x/2.2.x, the latest brew formula for
# cassandra is 3.x. We need to tap homebrew/versions and install cassandra22
# instead.
#
# 1. Uninstall old cassandras, if any
# Skip to #2 if no cassandra is installed
brew tap homebrew/versions
brew uninstall cassandra cassandra20
brew cleanup
# Delete leftovers as well
rm -rf /usr/local/etc/cassandra
# 2. Install/Start cassandra 2.2.x
brew install cassandra22
brew services start cassandra22
# 3. Install luarocks
brew install luajit luarocks
# 4. Install kong and its deps
luarocks install multipart lua-resty-iputils lapis kong
kong start
# Test
http get 127.0.0.1:8001
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment