Skip to main content

Posts

WKHTML pdf setup in Ubuntu

 wkhtml to pdf install on ubuntu 20.04 sudo apt-get install -y libxrender1 libfontconfig1 libx11-dev libjpeg62 libxtst6 fontconfig xfonts-75dpi xfonts-base libpng12-0 wget https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/0.12.5/wkhtmltox_0.12.5-1.xenial_amd64.deb #issue fix for: libpng12-0 sudo add-apt-repository ppa:linuxuprising/libpng12 sudo apt update sudo apt install libpng12-0 #Issue fix for: libssl1.0.0. Edit the source list sudo nano /etc/apt/sources.list to add the following line: deb http://security.ubuntu.com/ubuntu xenial-security main Then sudo apt update and sudo apt install libssl1.0.0. #source link: https://askubuntu.com/questions/1261614/ubuntu-20-04-libssl-so-1-0-0-cannot-open-shared-object-file-no-such-file-or-d sudo dpkg -i wkhtmltox_0.12.5-1.xenial_amd64.deb sudo apt-get -f install
Recent posts

Wordpress Setup using the Xampp.

                       Wordpress Setup using the Xampp.           STEPS: Install the XAMPP server. Link for the reference: https://www.apachefriends.org/download.html After installation, we need to run the Apache and Mysql start. Download the WordPress plugin from the website. Link for reference: https://wordpress.org/download/ We need to put the WordPress folder to xampp -> htdocs  We need to run the URL: http://localhost/wordpress/wp-admin/ We need to set up the WordPress configurations. Database name:  Db name            Username: root            Password:     (Empty)            Host: localhost          Once setup is done we can access the website. Appearance -> Themes...

Heroku Deployment in ROR?

Heroku Deployment in ROR?   git push origin main(branch name) heroku create -> Create the repository in heroku heroku push origin main(branch name) heroku db:migrate heroku logs => Checking the heroku logs heroku open -> Open the URL heroku pg:psql

Ruby on Rails Interview Questions Experienced

ROR Interview Questions Experienced  Difference between the map & each? The map will return the new array with modified values. Each will return the same array with an object. Write the  program to sort the array in ruby without using the sort method? def ary_sort(list, new_array = nil) return new_array if list.size <= 0 if new_array == nil min = list.min new_array = [] end ary_sort(list, new_array) new_array << min list.delete(min) end    ary_sort ([1,6,5,3,8,24,18]) Write the   Program for array pass the arguments?  Input will be a = [2,3,4] ,a.add_no(2)   ====> Output - [4,5,6] Array.class_eval do def add_no(n) self.map{|x| x+ n} end end Difference between the find and find_by in rails? find_by () returns the  nil if the record does not exist in the database find () returns the  ActiveRecord::RecordNotFound exception  f the record does not exist in the database. How do acc...

Error malloc(): memory corruption nginx with passenger?

Error malloc(): memory corruption nginx with passenger Passenger issue resolving steps :  sudo gem uninstall passenger(uninstall all passenger) sudo gem install passenger sudo passenger-install-nginx-module --auto --auto-download --prefix=/opt/nginx --extra-configure-flags=none Update nginx config file with new passenger version and restart the nginx