Commit c76b4eee authored by Alejandro Rodríguez's avatar Alejandro Rodríguez

Setup gitaly within the GDK

parent fc78d4c8
Pipeline #5527883 passed with stages
in 22 minutes and 34 seconds
......@@ -48,3 +48,4 @@
/gitlab-runner-config.toml
/.gdk-install-root
/builds
/gitaly/
......@@ -2,6 +2,7 @@ gitlab_repo = https://gitlab.com/gitlab-org/gitlab-ce.git
gitlab_shell_repo = https://gitlab.com/gitlab-org/gitlab-shell.git
gitlab_workhorse_repo = https://gitlab.com/gitlab-org/gitlab-workhorse.git
gitlab_workhorse_clone_dir = gitlab-workhorse/src/gitlab.com/gitlab-org/gitlab-workhorse
gitaly_repo = https://gitlab.com/gitlab-org/gitaly.git
gitlab_development_root = $(shell pwd)
postgres_bin_dir = $(shell pg_config --bindir)
postgres_replication_user = gitlab_replication
......@@ -12,7 +13,7 @@ username = $(shell whoami)
sshd_bin = $(shell which sshd)
git_bin = $(shell which git)
all: gitlab-setup gitlab-shell-setup gitlab-workhorse-setup support-setup
all: gitlab-setup gitlab-shell-setup gitlab-workhorse-setup support-setup gitaly-setup
# Set up the GitLab Rails app
......@@ -75,9 +76,16 @@ gitlab-shell/config.yml:
gitlab-shell/.gitlab_shell_secret:
ln -s ${gitlab_development_root}/gitlab/.gitlab_shell_secret $@
# Update gitlab, gitlab-shell and gitlab-workhorse
# Set up gitaly
update: gitlab-update gitlab-shell-update gitlab-workhorse-update
gitaly-setup: gitaly/.git
gitaly/.git:
git clone ${gitaly_repo} gitaly
# Update gitlab, gitlab-shell, gitlab-workhorse and gitaly
update: gitlab-update gitlab-shell-update gitlab-workhorse-update gitaly-update
gitlab-update: gitlab/.git/pull
cd ${gitlab_development_root}/gitlab && \
......@@ -106,6 +114,21 @@ gitlab-shell/.git/pull:
git stash && git checkout master && \
git pull --ff-only
gitaly-update: gitaly/.git/pull gitaly-clean gitaly/bin/gitaly
gitaly/.git/pull:
cd ${gitlab_development_root}/gitaly && \
git stash && git checkout master && \
git pull --ff-only
gitaly-clean:
cd ${gitlab_development_root}/gitaly && \
make clean
gitaly/bin/gitaly:
cd ${gitlab_development_root}/gitaly && \
make
# Set up supporting services
support-setup: .ruby-version foreman Procfile redis postgresql openssh-setup nginx-setup
......
......@@ -13,3 +13,4 @@ rails-background-jobs: exec /usr/bin/env SIDEKIQ_LOG_ARGUMENTS=1 RAILS_ENV=devel
#grafana: exec support/wait-postgresql-ready support/exec-cd grafana bin/grafana-server -config grafana.ini
#sshd: exec /usr/sbin/sshd -e -D -f /home/git/openssh/sshd_config
#nginx: exec nginx -p /home/git/nginx -c conf/nginx.conf
#gitaly: exec /usr/bin/env PATH="/home/git/gitaly:$PATH" gitaly
......@@ -55,7 +55,7 @@ db() {
app() {
print_port
foreman_start -c all=0,rails-web=1,rails-background-jobs=1,gitlab-workhorse=1,nginx=1,grafana=1,sshd=1
foreman_start -c all=0,rails-web=1,rails-background-jobs=1,gitlab-workhorse=1,nginx=1,grafana=1,sshd=1,gitaly=1
}
grafana() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment