by devokot
29 deployments · 18 still active · last rev. 2 years ago

Sets up a Gitlab, copied and modified from another stackscript

Default username is root with password

Compatible with: Ubuntu 14.04 LTS
# <UDF name="HOSTNAME" Label="Host Name for VM" example="gitlab"/>
# <UDF name="FQDN" Label="Fully Qualified Domain Name" example="" />
# <UDF name="URL" Label="Full URL for new gitlab site" example="" />

source <ssinclude StackScriptID="1">

system_set_hostname "$HOSTNAME"
system_add_host_entry "$(system_primary_ip)" "$FQDN"

# Set directives to allow for silent postfix install, this will create an "Internet Site" for postfix
debconf-set-selections <<< "postfix postfix/mailname string $FQDN"
debconf-set-selections <<< "postfix postfix/main_mailer_type string 'Internet Site'"

# Install Pre Reqs
apt-get -y install wget openssh-server postfix

# Download and Install gitlab
# curl -s | sudo bash
# sudo apt-get install gitlab-ce

# Download and Install gitlab from package
dpkg -i download

# Configure gitlab with Site URL
echo "external_url '$URL'" > /etc/gitlab/gitlab.rb

# Launch gitlab
gitlab-ctl reconfigure