Gitlab and sslerror in sending mails

There was a gitlab (10.4) and everything was fine, but one day, mails stopped coming. I opened the console (sudo gitlab-ctl tail) and found a sore – OpenSSL::SSL::SSLError: SSL_connect returned = 1 errno = 0 state = error: certificate verify failed . Without thinking for a long time i ran to the admins.

They changed the certificate to globalsign on the server. Ok, I went into the ruby ​​console – checked the configuration (the commands were taken from here ):

# sudo gitlab-rails console production
irb(main):002:0> ActionMailer::Base.smtp_settings
=> {:authentication =>:login,:address => "X.X.ru",:port => 587,:user_name => "X@X.ru",: password => "XXX",: domain => "X.X.ru",:enable_starttls_auto => true,:openssl_verify_mode =>"peer",: ca_file =>"/opt/gitlab/embedded/ssl/certs/cacert.pem"}

It looks good, the admin gave the updated file cacert.pem, i replaced. Of course, did not forget to run sudo gitlab-ctl reconfigure .
Then i tried the test sending:

# sudo gitlab-rails console production
irb(main):002:0> Notify.test_email('youremail@email.com','Hello World','This is a test message'). deliver_now
=> OpenSSL::SSL::SSLError:SSL_connect returned = 1 errno = 0 state = error: certificate verify failed ...

Unclear. Okay, I got here and decided to test the certificate:

# /opt/gitlab/embedded/bin/openssl x509 -in /opt/gitlab/embedded/ssl/certs/cacert.pem -text -noout

No, it’s okay, readed successfully.
To hell, put gitlab_rails [‘smtp_openssl_verify_mode’] = ‘none’ in /etc/gitlab/gitlab.rb, rerun sudo gitlab-ctl reconfigure . And the test mail was sent! As it turned out, I was happy too early. All other mails still caught the error. For some reason, this configuration worked only for test sending?
Then the admin suggested simply to restart the server, and I found that ubuntu really wants it:

Welcome to Ubuntu 16.04.1 LTS (GNU / Linux 4.4.0-83-generic x86_64)

83 packages can be updated.
1 updates are security updates.

*** System restart required ***

Looked who wants reboot:

# more /var/run/reboot-required.pkgs
ssl1.0.0

Just like our guy! Legs in hand – sudo reboot and the mails again learned to fly like before!

28
Add comment

avatar
28 Comment threads
0 Thread replies
0 Followers
 
Most reacted comment
Hottest comment thread
2 Comment authors
KennethalosyJosephSeithRobertevaRaCharlesdohagJamesGlymn Recent comment authors
newest oldest most voted
Jamestot
Guest
Jamestot

https://bjdkgfsfhidhgvudbfjeguehfwhsfug.com
Mkfdkfjwsldjeifgheifnkehgjr
vndkfhsjfodkfc;sjgjdgokrpgkrp
bndljgoedghoekfpegorig
fihfowhfiehfoejogtjrir
Yndkfvhdjkfhke nkfnslkfn klfnklf
Oljgvkdfkndjvbgdjffsjdnkjdhf

Nkfhofjeojfoegoero ogeoegfeougeihigoohge igjeigheiogheiogheih giehdgoiehifoehgioheighe hfioeehfieohgeiodgnei hioehgioehfdkhgioehgi eodghioedhgieghiehgeuo
Nihdigheifjojfieui iihfishfiwsfhiwhfowhfh hfsdfhkdcndjkfhe klchsiofhwifhdvjdnj hkfhsfhifheuhguegheflkhe
Yfhsfheifhei hfhdfiehfiejfk fjeogjeogj ojgoedjodjvsclksfhszghLhekjb; ;dh jdjvndkjdfjsofjsofjosjfi fojsjdoskfsjfodgjdsghoi sdjfpfgspegjsodjvdhvgisd
Mfjefjojgidhvshg ihidhgiodhgirhgir hioihgdioghrigrigh ihgiogherihgirodvdks jsdjfsopejfovgjdksjosj joesjfoesjfsj;ifsjg
Ndjsfhjifekfhekdghior highdiofhidogheioghei gijhgoiehgiehgieh jfiheigheihgioe

JamesGlymn
Guest
JamesGlymn
Michaelsoops
Guest
Michaelsoops
Brianinaxy
Guest
Brianinaxy
JeremyJix
Guest
JeremyJix
JamesGlymn
Guest
JamesGlymn
JamesGlymn
Guest
JamesGlymn
JamesGlymn
Guest
JamesGlymn
RobertevaRa
Guest
RobertevaRa
JosephSeith
Guest
JosephSeith

Meds information for patients. Cautions. can i buy lyrica tablets Everything what you want to know about drugs. Read information now.

JosephSeith
Guest
JosephSeith

Pills information leaflet. What side effects can this medication cause? order generic trazodone price Everything trends of meds. Get information now.

JosephSeith
Guest
JosephSeith

Medicament information sheet. Cautions. generic trazodone online Best news about pills. Get here.

JosephSeith
Guest
JosephSeith

Meds information. Generic Name. buying generic lisinopril without a prescription Everything what you want to know about drug. Get here.

RobertevaRa
Guest
RobertevaRa

Medicines information for patients. Cautions. lisinopril tablets Medicines information for patients. Short-Term Effects.

RobertevaRa
Guest
RobertevaRa

Medication information. What side effects can this medication cause? generic viagra canada pharmacy Best trends of meds. Get here.

RobertevaRa
Guest
RobertevaRa

Medicine information. Effects of Drug Abuse. buying viagra without prescription Actual what you want to know about medicines. Read now.

RobertevaRa
Guest
RobertevaRa

Meds information for patients. What side effects? generic viagra sale Best news about drug. Get now.

RobertevaRa
Guest
RobertevaRa

Medicines information sheet. Cautions. viagra generic online Actual news about drug. Read information here.

RobertevaRa
Guest
RobertevaRa

Medicines information. Effects of Drug Abuse. buy viagra All trends of medicament. Get information here.

RobertevaRa
Guest
RobertevaRa

Medication information sheet. Effects of Drug Abuse. where to buy generic viagra Some trends of medicament. Get here.

RobertevaRa
Guest
RobertevaRa

Medication information. Brand names. buy viagra cheap Everything information about medicament. Get now.

JosephSeith
Guest
JosephSeith

Medicine information. What side effects? where to buy cheap prozac without prescription Everything information about medicines. Read now.

Charlesdohag
Guest
Charlesdohag
JosephSeith
Guest
JosephSeith

Medicament information. Effects of Drug Abuse. can i purchase lexapro pills All news about medication. Get here.

RobertevaRa
Guest
RobertevaRa

Pills information. What side effects can this medication cause? buying cheap viagra Some trends of medicines. Get now.

RobertevaRa
Guest
RobertevaRa

Drug information. What side effects? how can i get cheap accupril for sale Some information about drug. Get information now.

JosephSeith
Guest
JosephSeith

Medicines information sheet. Short-Term Effects. order cheap lyrica no prescription Actual information about pills. Read here.

Kennethalosy
Guest
Kennethalosy

Drugs information sheet. Long-Term Effects. https://lyricacvc.com/ Everything news about pills. Get information now.