2 mins read

Setup SMTP Dengan Gem Figaro



Setup SMTP Dengan Gem Figaro

Apa itu figaro?
Figaro adalah gem pada ruby on rails yang digunakan untuk menyembunyikan nilai di environment dan membuat aplikasi lebih aman.

Seberapa penting figaro?
Tentu sangat penting, dikarenakan banyak kasus mengupload password  ke repository github secara public, contoh kasus:commit remove password.
Agar aplikasi kita lebih aman dan tidak seperti kasus diatas alangkah baiknya untuk menggunakan gem figaro ini, agar file application.yml otomatis tidak akan terupload ke repository.

Install Figaro


1.Buat rails project baru


2.Lalu tambahkan gem figaro pada gemfile
 gem 'figaro'

3.Jalankan commend dibawah ini untuk install figaro

$ bundle exec figaro install

4.Buka folder aplikasi & masukan kode dibawah ini pada file figaro/config/application.yml

Di file ini kita bisa setting smtp dll.
Saya akan contohkan untuk setting smtp menggunakan figaro.

smtp_domain: gmail.com
smtp_authentication: plain
smtp_username: email anda
smtp_password: password email anda

5.Ketikan kode dibawah ini pada file figaro/environments/development.rb

 config.action_mailer.smtp_settings = {
      :address => ENV["smtp_address"],
      :port => 587,
      :domain => ENV["smtp_domain"],
      :authentication => ENV["smtp_authentication"],
      :enable_starttls_auto => true,
      :user_name => ENV["smtp_username"],
      :password => ENV["smtp_password"]'
}

untuk selebihnya mengenai gem figaro bisa klik link dibawah ini:

Selamat mencoba & happy coding :)

PakarPBN

A Private Blog Network (PBN) is a collection of websites that are controlled by a single individual or organization and used primarily to build backlinks to a “money site” in order to influence its ranking in search engines such as Google. The core idea behind a PBN is based on the importance of backlinks in Google’s ranking algorithm. Since Google views backlinks as signals of authority and trust, some website owners attempt to artificially create these signals through a controlled network of sites.

In a typical PBN setup, the owner acquires expired or aged domains that already have existing authority, backlinks, and history. These domains are rebuilt with new content and hosted separately, often using different IP addresses, hosting providers, themes, and ownership details to make them appear unrelated. Within the content published on these sites, links are strategically placed that point to the main website the owner wants to rank higher. By doing this, the owner attempts to pass link equity (also known as “link juice”) from the PBN sites to the target website.

The purpose of a PBN is to give the impression that the target website is naturally earning links from multiple independent sources. If done effectively, this can temporarily improve keyword rankings, increase organic visibility, and drive more traffic from search results.

Jasa Backlink

Download Anime Batch