42 lines
1.2 KiB
Markdown
42 lines
1.2 KiB
Markdown
---
|
|
title: Gitea Installation Guide
|
|
name: gitea-installation
|
|
summary: Install Gitea on a VPS to set up a self-hosted Git service.
|
|
description: A step-by-step guide to installing Gitea on a VPS for a self-hosted Git service.
|
|
---
|
|
|
|
### Objective
|
|
Install Gitea on a VPS to set up a self-hosted Git service.
|
|
|
|
### Steps
|
|
1. **Install Dependencies**:
|
|
```sh
|
|
sudo apt update
|
|
sudo apt install -y git curl
|
|
````
|
|
|
|
2. **Download and Install Gitea**:
|
|
```sh
|
|
curl -fsSL https://raw.githubusercontent.com/go-gitea/gitea/master/contrib/docker/install.sh | sudo GITEA_VERSION=latest bash
|
|
````
|
|
|
|
3. **Start and Enable Gitea Service**:
|
|
```sh
|
|
sudo systemctl enable gitea
|
|
sudo systemctl start gitea
|
|
````
|
|
|
|
4. **Check Gitea Service Status**:
|
|
```sh
|
|
sudo systemctl status gitea
|
|
````
|
|
|
|
5. **Access Gitea**:
|
|
Once Gitea is running, you can access it via your browser at `http://77.93.152.242:3001`.
|
|
|
|
### Notes
|
|
- Ensure that port `3001` is open on the VPS.
|
|
- If there are any errors during installation, check the logs for more details.
|
|
|
|
### Troubleshooting
|
|
- If the installation script fails, try downloading the Gitea binary manually from the [official website](https://gitea.io/). |