raspi-config
- Change password
- Expand filesystem
- Change resolution (optional)
- Set boot state (optional)
- Set hostname to gitlab (optional)
sudo apt update
sudo apt full-upgrade
sudo apt clean
Open file
sudo nano /etc/dhcpcd.conf
interface wlan0
static ip_address=192.168.1.20/24
static routers=192.168.1.1
static domain_name_servers=1.1.1.1
Reboot
sudo reboot
sudo apt install realvnc-vnc-server realvnc-vnc-viewer
Enable VNC with raspi-config
Format drive
sudo mkfs.ext4 /dev/sda1 -L untitled
Mount drive
sudo mkdir /mnt/storage
sudo chown pi /mnt/storage
sudo mount /dev/sda1 /mnt/storage
Setup automount
sudo blkid
- get UUID
sudo nano /etc/fstab
UUID=91ce2c4f-44cc-4c39-9954-c00595c0821b /mnt/storage ext4 defaults 0 0
Remove drive while pi is powered
sudo umount /dev/sda1
For NTFS filesystems (has a performance hit)
sudo apt-get install ntfs-3g
Stop swap
sudo dphys-swapfile swapoff
Open file
sudo nano /etc/dphys-swapfile
Modify max swap size
CONF_MAXSWAP=4096
Modify swap size
CONF_SWAPSIZE=4096
Change swap location
CONF_SWAPFILE=/mnt/storage/swap
Initialize new file location
sudo dphys-swapfile setup
Restart swap
sudo dphys-swapfile swapon
curl -Lo gitlab-ce_12.9.10-ce.0_armhf.deb https://packages.gitlab.com/gitlab/raspberry-pi2/packages/raspbian/stretch/gitlab-ce_12.9.10-ce.0_armhf.deb/download.deb
sudo apt install ./gitlab-ce_12.9.10-ce.0_armhf.deb
Open file
sudo nano /etc/gitlab/gitlab.rb
Set these settings
external_url 'http://192.168.1.20:8888'
unicorn['enable'] = false
puma['enable'] = true
puma['worker_processes'] = 2
sidekiq['concurrency'] = 9
prometheus_monitoring['enable'] = false
git_data_dirs({"default" => {"path" => "/mnt/storage/git-data"}})
sudo gitlab-ctl reconfigure
sudo gitlab-ctl start
sudo gitlab-ctl stop
sudo gitlab-ctl restart