change gitlab_home to gitlab_app_root

This commit is contained in:
Praveen Arimbrathodiyil 2016-02-18 14:31:41 +05:30
parent 235a16129c
commit 3ba2b5b56c
6 changed files with 10 additions and 10 deletions

4
debian/conf/gitlab vendored
View file

@ -9,7 +9,7 @@ RAILS_ENV="production"
# Read and export debian specific configuration
# Only exported variables will be passed on to gitlab app
export $(cat /etc/gitlab/gitlab-debian.conf|xargs)
export $(cat /etc/gitlab/gitlab-debian.conf)
# app_user defines the user that GitLab is run as.
# The default is "git".
@ -17,7 +17,7 @@ app_user=${gitlab_user}
# app_root defines the folder in which gitlab and it's components are installed.
# The default is "/home/$app_user/gitlab"
app_root=${gitlab_home}
app_root=${gitlab_app_root}
# gitlab_log_dir is defined in /etc/gitlab/gitlab-debian.conf

View file

@ -2,7 +2,7 @@ RAILS_ENV=production
DB=postgres
gitlab_user=gitlab
gitlab_conf=/etc/gitlab.conf
gitlab_home=/usr/share/gitlab
gitlab_app_root=/usr/share/gitlab
gitlab_data_dir=/var/lib/gitlab
gitlab_scripts=/usr/lib/gitlab/scripts
gitlab_nginx_log=/var/log/gitlab

View file

@ -21,7 +21,7 @@ EnvironmentFile=/etc/gitlab/gitlab-debian.conf
SyslogIdentifier=gitlab-workhorse
PIDFile=/run/gitlab/gitlab-workhorse.pid
ExecStart=/usr/share/gitlab/bin/daemon_with_pidfile ${gitlab_pid_path}/gitlab-workhorse.pid gitlab-workhorse -listenUmask 0 -listenNetwork unix -listenAddr ${gitlab_pid_path}/gitlab-workhorse.socket -authBackend http://127.0.0.1:8080 -authSocket ${gitlab_pid_path}/gitlab.socket -documentRoot ${gitlab_home}/public >> ${gitlab_log_dir}/gitlab-workhorse.log 2>&1
ExecStart=/usr/share/gitlab/bin/daemon_with_pidfile ${gitlab_pid_path}/gitlab-workhorse.pid gitlab-workhorse -listenUmask 0 -listenNetwork unix -listenAddr ${gitlab_pid_path}/gitlab-workhorse.socket -authBackend http://127.0.0.1:8080 -authSocket ${gitlab_pid_path}/gitlab.socket -documentRoot ${gitlab_app_root}/public >> ${gitlab_log_dir}/gitlab-workhorse.log 2>&1
[Install]
WantedBy=multi-user.target

View file

@ -30,7 +30,7 @@ worker_processes 3
# Help ensure your application will always spawn in the symlinked
# "current" directory that Capistrano sets up.
working_directory ENV['gitlab_home'] # available in 0.94.0+
working_directory ENV['gitlab_app_root'] # available in 0.94.0+
# Listen on both a Unix domain socket and a TCP port.
# If you are load-balancing multiple Unicorn masters, lower the backlog

6
debian/postinst vendored
View file

@ -53,15 +53,15 @@ case "$1" in
chmod -R ug+rwX,o-rwx ${gitlab_repo_path}/
chmod -R ug-s ${gitlab_repo_path}/
find ${gitlab_repo_path}/ -type d -print0 | xargs -0 chmod g+s
for i in ${gitlab_home} ${gitlab_data_dir} ${gitlab_shell_root}; do
for i in ${gitlab_app_root} ${gitlab_data_dir} ${gitlab_shell_root}; do
chown -R ${gitlab_user}: $i
done
su ${gitlab_user} -s /bin/sh -c "chmod 750 ${gitlab_uploads_path}"
su ${gitlab_user} -s /bin/sh -c 'git config --global core.autocrlf "input"'
# Commands below needs to be run from gitlab_home
cd ${gitlab_home}
# Commands below needs to be run from gitlab_app_root
cd ${gitlab_app_root}
# Obtain hostname from debconf db
db_get gitlab/fqdn

View file

@ -28,8 +28,8 @@ fi
# Workaround for #813770
if [ "${GITLAB_HTTPS}" = "true" ]; then
gl_proto="https"
sed -i "s/#port: 80/port: 443/" ${gitlab_home}/config/gitlab.yml
sed -i "s/https: false/https: true/" ${gitlab_home}/config/gitlab.yml
sed -i "s/#port: 80/port: 443/" ${gitlab_app_root}/config/gitlab.yml
sed -i "s/https: false/https: true/" ${gitlab_app_root}/config/gitlab.yml
else
gl_proto="http"
fi