Setting up the SMTP Gmail service for the gitlab CE local server at ubuntu 14.04

If you would rather send application email via an SMTP server instead of via Sendmail, add the following configuration information to /etc/gitlab/gitlab.rb and run gitlab-ctl reconfigure.

 

gitlab_rails['smtp_enable'] = true
gitlab_rails['smtp_address'] = "smtp.gmail.com"
gitlab_rails['smtp_port'] = 587
gitlab_rails['smtp_user_name'] = "my.email@gmail.com"
gitlab_rails['smtp_password'] = "my-gmail-password"
gitlab_rails['smtp_domain'] = "smtp.gmail.com"
gitlab_rails['smtp_authentication'] = "login"
gitlab_rails['smtp_enable_starttls_auto'] = true
gitlab_rails['smtp_tls'] = false
gitlab_rails['smtp_openssl_verify_mode'] = 'peer' # Can be: 'none', 'peer', 'client_once', 'fail_if_no_peer_cert', see http://api.rubyonrails.org/classes/ActionMailer/Base.html

Don't forget to change my.email@gmail.com to your email address and my-gmail-password to your own password.


Creating Local GitLab Repo Server at ubuntu14.04

 

Ref: https://about.gitlab.com/downloads/#ubuntu1404

Git Installation and usages

In Linux ubuntu

sudo apt-get install git-core
cd /apt/lampp/htdocs (or) cd /var/www/html

clone project to your local
sudo git clone http://tester@127.0.0.1:8080/test.git

checking all git branches
git branch -a

checking current git branch
git branch

pulling / downloading the latest files
git pull

change to the other branch by checkout
git checkout dedicated_branch

checking the edited files
git diff file

adding edited file to comit
git add file

commit edited files to push
git commit -m “About the commit”

push the edited files
git push

Git – Force Overwrite of Untracked Working Tree Files

Sometimes we got error ” error: Your local changes to the following files would be overwritten by checkout: ” while we run ” git pull ” or ” git checkout branch “. In that case, if we want to overwrite these files. So what do we do? We use the following:

git fetch –all
git reset –hard origin/master

This grabs the latest repository files without merging and resets the master branch and overwrites the modified ones.