-
Notifications
You must be signed in to change notification settings - Fork 2
Getting Started with IP Database
This project depends on Ruby and Rails. Let's get you set up.
Curl will help our installer download the dependencies.
sudo apt-get install curl
Git will work wonders for us in the near future.
sudo apt-get install git
Let's get your git configured.
git config --global user.name "Your Name Here"
git config --global user.email "[email protected]"
Now we'll need to get mysql.
sudo apt-get install mysql-client
sudo apt-get install mysql-server
Now we'll get RVM which will manage all of the different versions of Ruby that can be installed in your environment. It will also fetch gem for us and let us manage gemsets.
curl -L https://get.rvm.io | bash -s stable --ruby
As soon as this script finishes, it will tell you to run a source command that puts rvm in your shell path. Run that command and then use which to check that it succeeded. Ubuntu doesn't come with zlib installed, so we'll use rvm to fetch that for us.
rvm pkg install ree_dependencies
After this finishes, it will give you two commands to run that will recompile all of the gem currently installed. For us, this should be only about three.
Now, we'll install our ruby.
rvm install 1.9.3
After this, we can start setting up our gemsets.
rvm gemset create ip; rvm use @ip
Let's download the repository and get to work!
git clone https://github.com/amalvagomes/ip-database.git
- No commits to master
- No work-in-progress commits
- Branch from develop and work in your own branch until your feature is tested and complete
- Always pull from develop and resolve merge conflicts before making the final push to your branch
- Send pull requests to be merged into develop when you have made your final push
Assuming you have created the mysql databases listed in config/database.yml, you'll just need to update the credentials in that file and then boot the app.
It's as simple as changing to the root directory of the repository and running this command!
rails server
Then just go to your web browser and visit http://localhost:3000/