mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-25 11:22:16 +00:00
General documentation cleanup (#3317)
* Clean up spelling, grammar, perspective, whitespace, language, markup, etc.
This commit is contained in:
parent
923c0105f4
commit
3ee8be3849
30 changed files with 500 additions and 279 deletions
|
@ -13,56 +13,55 @@ menu:
|
|||
identifier: "linux-service"
|
||||
---
|
||||
|
||||
### Run as service in Ubuntu 16.04 LTS
|
||||
|
||||
#### Using systemd
|
||||
### Run as service in Ubuntu 16.04 LTS
|
||||
|
||||
Run below command in terminal:
|
||||
#### Using systemd
|
||||
|
||||
Run the below command in a terminal:
|
||||
```
|
||||
sudo vim /etc/systemd/system/gitea.service
|
||||
```
|
||||
|
||||
Add code to the file from [here](https://github.com/go-gitea/gitea/blob/master/contrib/systemd/gitea.service).
|
||||
|
||||
Uncomment any service need to be enabled like mysql in this case in Unit section.
|
||||
|
||||
Change the user(git) accordingly to yours. And /home/git too if your username is different than git. Change the PORT or remove the -p flag if default port is used.
|
||||
|
||||
Lastly start and enable gitea at boot:
|
||||
```
|
||||
sudo systemctl start gitea
|
||||
```
|
||||
|
||||
Copy the sample [gitea.service](https://github.com/go-gitea/gitea/blob/master/contrib/systemd/gitea.service).
|
||||
|
||||
Uncomment any service that needs to be enabled on this host, such as MySQL.
|
||||
|
||||
Change the user, home directory, and other required startup values. Change the
|
||||
PORT or remove the -p flag if default port is used.
|
||||
|
||||
Enable and start gitea at boot:
|
||||
```
|
||||
sudo systemctl enable gitea
|
||||
```
|
||||
sudo systemctl start gitea
|
||||
```
|
||||
|
||||
|
||||
#### Using supervisor
|
||||
#### Using supervisor
|
||||
|
||||
Install supervisor by running below command in terminal:
|
||||
Install supervisor by running below command in terminal:
|
||||
```
|
||||
sudo apt install supervisor
|
||||
```
|
||||
|
||||
Create a log dir for the supervisor logs(assuming gitea is installed in /home/git/gitea/):
|
||||
```
|
||||
mkdir /home/git/gitea/log/supervisor
|
||||
```
|
||||
|
||||
Open supervisor config file in vi/vim/nano etc.
|
||||
Create a log dir for the supervisor logs:
|
||||
```
|
||||
# assuming gitea is installed in /home/git/gitea/
|
||||
mkdir /home/git/gitea/log/supervisor
|
||||
```
|
||||
|
||||
Open supervisor config file in a file editor:
|
||||
```
|
||||
sudo vim /etc/supervisor/supervisord.conf
|
||||
```
|
||||
|
||||
And append the code at the end of the file from [here](https://github.com/go-gitea/gitea/blob/master/contrib/supervisor/gitea).
|
||||
|
||||
Change the user(git) accordingly to yours. And /home/git too if your username is different than git. Change the PORT or remove the -p flag if default port is used.
|
||||
|
||||
Lastly start and enable supervisor at boot:
|
||||
```
|
||||
sudo systemctl start supervisor
|
||||
```
|
||||
|
||||
Append the configuration from the sample
|
||||
[supervisord config](https://github.com/go-gitea/gitea/blob/master/contrib/supervisor/gitea).
|
||||
|
||||
Change the user(git) and home(/home/git) settings to match the deployment
|
||||
environment. Change the PORT or remove the -p flag if default port is used.
|
||||
|
||||
Lastly enable and start supervisor at boot:
|
||||
```
|
||||
sudo systemctl enable supervisor
|
||||
```
|
||||
|
||||
sudo systemctl start supervisor
|
||||
```
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue