Gitea will guide you through the initial configuration:
1
Configure database
The default SQLite configuration is perfect for getting started:
Database Type: SQLite3 (pre-selected)
Path: Default value is fine
SQLite requires no additional setup and is perfect for small to medium installations. You can migrate to PostgreSQL or MySQL later if needed.
2
Configure basic settings
Adjust these settings for your environment:
For Local Development
For Production/Remote Server
Server Domain: localhost
SSH Server Port: 222
Gitea Base URL: http://localhost:3000/
Keep the defaults - they work great for local testing!
Server Domain: Your domain or IP (e.g., git.example.com)
SSH Server Port: 222 (or 22 if not using Docker)
Gitea Base URL: http://your-domain-or-ip:3000/
Make sure to use your actual domain or IP address that users will use to access Gitea.
3
Create administrator account
Scroll down to the “Administrator Account Settings” section:
Administrator Username: Choose your admin username (e.g., admin)
Password: Choose a strong password
Email: Your email address
Keep these credentials safe! This account has full control over your Gitea instance.
4
Install Gitea
Click the “Install Gitea” button at the bottom of the page.The installation takes just a few seconds. You’ll be redirected to the login page when complete.
# Pull the latest imagedocker pull gitea/gitea:latest# Stop and remove the old containerdocker stop giteadocker rm gitea# Start with the new image (use your original docker run command)docker run -d \ --name=gitea \ -p 3000:3000 \ -p 222:22 \ -v gitea-data:/data \ gitea/gitea:latest
Your data is safe in the Docker volume and will persist across container updates.