Install Docker Desktop for your Silicon Mac, start it, and open Terminal to run the Docker Pull Command. Once you got the image added to Docker, use the Docker Dashboard to configure the image and run the container for the first time. For the Docker Pull Command click on one of the images above. For any unused image shown in the Dashboard, click the Run symbol in the Actions column to enter settings and generate a container from the image.
IMPORTANT: Make sure that Docker Desktop has grpcFuse set for file sharing (and not VirtioFS) - in Docker Preferences, General tab. Otherwise Postgres trouble. Check the Volumes table below. Create folder lab4dev, and also the three folders config, data, logs inside it. Of course feel free to rename lab4dev.
Click “Run”, in the window that pops up fill in the data like so:
myGitLab Community Edition
See your Mac’s “System Settings/Sharing” for your Mac’s local hostname. The root password really needs to be strong, “testing123” won’t work. Click the “Run” button, wait 5 minutes, enjoy your GitLab container. GitLab will be at localhost and on the local network at mySiliconMac.local
A fake SMTP server would catch and display the emails sent by GitLab. For example, smtp4dev can do this, and it can also relay emails to a real send mail server. Run docker pull rnwood/smtp4dev to pull its image from hub.docker.com , create folder smtp4dev_data , than run the image with the following options to make a container:
Run the image with the typed in options. The container will be available at localhost:3000 and at mySiliconMac.local:3000
Note: Smtp4dev is also available on GitHub.
Just for fun, check the Docker network, and the containers on it, with Terminal:
docker network ls
docker network inspect bridge
The default Docker network is named bridge.
Edit /users/my_user_name/lab4dev/config/gitlab.rb with your preferred plain text editor, to configure the SMTP settings.
Add the following lines to the SMTP settings section:
### GitLab email server settings
###! Docs: https://docs.gitlab.com/omnibus/settings/smtp.html
###! **Use smtp instead of sendmail/postfix.**
gitlab_rails['smtp_enable'] = true
gitlab_rails['smtp_address'] = "mySiliconMac.local"
gitlab_rails['smtp_port'] = 25
gitlab_rails['smtp_tls'] = false
gitlab_rails['smtp_openssl_verify_mode'] = 'none'
gitlab_rails['smtp_enable_starttls_auto'] = false
gitlab_rails['smtp_ssl'] = false
gitlab_rails['smtp_force_ssl'] = false
gitlab_rails['smtp_user_name'] = ""
gitlab_rails['smtp_password'] = ""
gitlab_rails['smtp_authentication'] = "login"
GitLabCE: let the container run, execute in Docker Internal Terminal gitlab-ctl reconfigure to make the config happen. Smtp4dev: see the intercepted emails in the smtp4dev web interface - “allow remote connections” must be on.
Good luck and have fun!