Menu Close

How to Install gitea on Synology Using Docker


gitea is a very lightweight web git client that you can run on Synology NAS using Docker. This allows you to easily manage your git repositories with a web interface, and using username and password, rather than SSH keys to pull git containers. Using Synology’s built in reverse proxy you can also easily add https:// encryption.


  • a Synology NAS with Docker / Container manager (for DSM 7.2 and later) installed
  • Either a local static IP on the network or a DNS address pointing to the IP of your Synology

How to install gitea on Synology NAS Using docker

Step 1: Download the gitea docker container

Open up docker -> registry -> and search for gitea

Download the gitea/gitea container

download gitea container

You should then see the image downloaded in the Image tap of container manager

Gitea Docker image downloaded

Step 2: Launch the gitea docker container

After the container has downloaded select the gitea image and hit run

run the gitea container

This will launch a setup menu for the gitea docker container. Input the following parameters

Name the Container and Enable Auto Restart

Name the container whatever you want, and enable auto restart

Port Settings:

The gitea container requires two ports. 1 used for SSH, and 1 used for http pulling. By default your NAS will be using port 22 for its own SSH, so select port 4022 for the external port for ssh. The port 3000 should be unused on your NAS so you can just use that. Both will be TCP. Your port configuration should look like this after you are done:

gitea port settings

Volume Mapping:

The gitea docker container only needs a single configuration folder, /data. To do this on the volume mapping screen select + Add Folder. Then create a new folder under the docker shared folder called gitea. Select this folder. Then under the mapping section put /data and give it read write. Your volume settings should look like this when you are done:

That is the last of the docker container configuration! Now just hit done and the container will automatically start!

Step 3: Connect to the gitea docker container

The first time you boot the container it will take a few minutes to start up. After that go to http://<your NAS IP>:3000 in your browser. You should get brought a gitea setup screen.

Change the following variables to these values

Database TypeSQLite3 (other if you have a DB already running)
Site TitleWhatever you want it to be
Server DomainYour NAS IP or DNS name
SSH Server Port4022 (selected in the port mapping earlier)
Gitea Base URLhttp://<your NAS IP or DNS name>:3000/
Gitea configuration

and just hit Install Gitea. This process will take a couple of minutes

Step 4: Create your gitea admin account

After gitea is done installing you will be brought to a sign in screen. Select Register now and create a new account. The first account registered will become the admin account and have full site access.

Simply just create your new account

And you are done! You can now sign in and start creating your git repositories

Leave a Reply