Skip to content

Latest commit

 

History

History
32 lines (25 loc) · 1.6 KB

README.md

File metadata and controls

32 lines (25 loc) · 1.6 KB

Kkubby

Rails app that helps you organize your beauty products using shelves. Search for products from the supported catalogs (Peach & lily, Sephora, Soko Glam, SkinCeuticals)

Installation

  1. Setup the server with nginx (https://www.digitalocean.com/community/tutorials/how-to-install-nginx-on-ubuntu-18-04)
  2. Setup the server with RVM (https://github.com/rvm/ubuntu_rvm)
  3. Setup the server with nodejs and npm (sudo apt-get install nodejs yarn npm && npm install --global yarn) for webpacker
  4. Setup server with nvm to install correct node JS version (https://phoenixnap.com/kb/update-node-js-version)
  5. Setup SSL with letsencrypt (https://certbot.eff.org/lets-encrypt/ubuntubionic-nginx)
  6. Add the example nginx conf (.nginx.conf.example)
  7. Remember to add config to shared/config/database.yml and shared/config/master.key
  8. Remember to add rails env production in bashrc

Linux Server Configuration

This app comes with web scrapers to build and update the product catalogs. It uses the Apparition driver for Capybara. In order to install this on a Linux server, you need to install the chrome binary and set certain :browser_options when registering the driver.

Install Chrome
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo apt install -f ./google-chrome-stable_current_amd64.deb
Browser Options
Capybara.register_driver :apparition do |app|
  Capybara::Apparition::Driver.new(app, browser_options: { 'no-sandbox' => nil, 'disable-web-security' => nil, 'disable-features' => 'VizDisplayCompositor' })
end

This will enable visits to outside websites.