git clone [email protected]:rafayet-monon/google-search-extractor.git
cd google-search-extractor
ruby -v
The ouput should start with something like ruby 2.6.4
If not, install the right ruby version using rbenv (or rvm, whatever you prefer):
rbenv install 2.6.4
bundle && yarn
Using rails credentials.yml.enc and master.key(blog for details).
Use EDITOR='nano' rails credentials:edit
to create new credentials.
Sample credentials can be found in config/sample_credentials.yml
. Edit database and email credentials and paste it to
credentials.yml.enc
.
The mail is currently set up using google SMTP server. To configure your mail you have to add google user_name
and
password
. To do that open the credentials.ym.enc
and edit the below portion -
email:
user_name: 'your_google_email'
password: 'your_google_password'
rails db:create db:migrate db:seed
This application uses the following dependencies that is need to be installed -
- Redis to manage Sidekiq.
- Chromedriver for selenium to search in google.
To run the tests simply execute the below command within the application
rspec
First run the redis server
redis-server
Then within the application execute below command to start the application.
foreman start -f Procfile.dev
The application is deployed in heroku. As redis
is a service that
requires credit cards info to work in heroku
and I don't have one so file uploading and searching using Sidekiq
is not
available there. The search is done in runtime after uploading the file.
Requesting not to upload CSV file with large keyword set in heroku.
Demo User Credentials
email: [email protected]
password: 123123
Signup Page Login Page Forgot Password Page Update Profile Page Report Home Page Upload File Page Google HTML Page