2014-05-05 130 views
0

我可以跳過電子郵件確認步驟並啓用用戶嗎?gitlab無法通過smtp發送電子郵件

我後面跟着https://github.com/gitlabhq/gitlabhq/blob/6-4-stable/doc/install/installation.md 後面跟着每一步。 但我無法獲得電子郵件確認,因此無法確認用戶。

然後我端口1987

相同的設置上運行由rails s -p 1987 -e production服務器,我可以在其他機器上我自己的Rails應用程序接收電子郵件,

這很煩人我非常喜歡。

sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production

WARNING: Nokogiri was built against LibXML version 2.8.0, but has dynamically loaded 2.7.8 
Checking Environment ... 

Git configured for git user? ... yes 

Checking Environment ... Finished 

Checking GitLab Shell ... 

GitLab Shell version >= 1.9.3 ? ... OK (1.9.3) 
Repo base directory exists? ... yes 
Repo base directory is a symlink? ... no 
Repo base owned by git:git? ... yes 
Repo base access is drwxrws---? ... yes 
Satellites access is drwxr-x---? ... yes 
update hook up-to-date? ... yes 
update hooks in repos are links: ... can't check, you have no projects 
Running /home/git/gitlab-shell/bin/check 
Check GitLab API access: OK 
Check directories and files: 
    /home/git/repositories: OK 
    /home/git/.ssh/authorized_keys: OK 
Test redis-cli executable: redis-cli 2.2.12 
Send ping to redis server: PONG 
gitlab-shell self-check successful 

Checking GitLab Shell ... Finished 

Checking Sidekiq ... 

Running? ... yes 
Number of Sidekiq processes ... 1 

Checking Sidekiq ... Finished 

Checking LDAP ... 

LDAP is disabled in config/gitlab.yml 

Checking LDAP ... Finished 

Checking GitLab ... 

Database config exists? ... yes 
Database is SQLite ... no 
All migrations up? ... yes 
Database contains orphaned UsersGroups? ... no 
GitLab config exists? ... yes 
GitLab config outdated? ... no 
Log directory writable? ... yes 
Tmp directory writable? ... yes 
Init script exists? ... yes 
Init script up-to-date? ... yes 
projects have namespace: ... can't check, you have no projects 
Projects have satellites? ... can't check, you have no projects 
Redis version >= 2.0.0? ... yes 
Your git bin path is "/usr/local/bin/git" 
Git version >= 1.7.10 ? ... yes (1.8.5) 

Checking GitLab ... Finished 

production.rb

config.action_mailer.delivery_method = :smtp 
config.action_mailer.raise_delivery_errors = true 
config.action_mailer.default :charset => "utf-8" 


config.action_mailer.smtp_settings = { 
    :address => "74.125.129.109", 
    # :address => "smtp.gmail.com", 
    :port => 587, 
    :domain => "localhost", 
    :authentication => 'plain', 
    :user_name => XXX, 
    :password => XXX, 
    :enable_starttls_auto => true, 
    :openssl_verify_mode => 'none' 
    } 

回答

1

不知道如何跳過電子郵件確認,使用戶,但gitlab 6.7.5這些都是我的SMTP設置(iCloud的電子郵件服務器確保您已經登錄第一次進iCloud中的網絡電子郵件應用程序,至少一次):

文件:/用戶/混帳/ gitlab /配置/ initi alizers/smtp_settings.rb

# To enable smtp email delivery for your GitLab instance do next: 
# 1. Rename this file to smtp_settings.rb 
# 2. Edit settings inside this file 
# 3. Restart GitLab instance 
# 
if Rails.env.production? 
    Gitlab::Application.config.action_mailer.delivery_method = :smtp 

    ActionMailer::Base.smtp_settings = { 
    address: "smtp.mail.me.com", 
    port: 587, 
    user_name: "[email protected]", 
    password: "yourpasswd", 
    domain: "me.com", 
    authentication: "plain", 
    enable_starttls_auto: true 
    } 
end 

還記得改變EMAIL_FROM attrbiute在gitlab.yml文件:

文件:/Users/git/gitlab/config/gitlab.yml

## Email settings 
# Email address used in the "From" field in mails sent by GitLab 
email_from: [email protected] 

更改smtp文件後,重新啓動gitlab服務。

希望這會有所幫助。

乾杯,

相關問題