Gogs
Gogs is an open-source service that provides a web-based user interface for managing code repositories. It also lets you create and manage repositories, push, clone, and pull code, and collaborate with others. You can also use extensions and webhooks to integrate Gogs with other services. Its easy installation and small footprint have made it a popular choice for developers.
In this guide, we install Gogs together with PostgreSQL with just one click.
One-Click Deployment
With Arvancloud Cloud Container ready-made applications, you can set up Gogs with just one click.
Using Gogs
After the application is deployed on the Arvancloud Cloud Container, you can access Gogs through the free Arvancloud domain or your own domain (if you set it on this application).
Since Gogs needs a connection to a database to store data, if you don't already have a database for it, you first need to create one.
For example, create a PostgreSQL database with the Cloud Container ready-made applications and enter it through the console with this command:
psql --username=postgres
Note that you need to replace postgres with your own username.
Then create a database named gogs in it with the following command:
CREATE DATABASE gogs
ENCODING 'UTF8'
LC_COLLATE = 'en_US.UTF-8'
LC_CTYPE = 'en_US.UTF-8'
TEMPLATE template0
OWNER postgres;
Now you can go to Gogs using your own or Arvancloud domain and make its initial settings.
Initial Settings
When you open the Gogs domain in your browser, you see a page for its initial settings. In the first section, enter the database settings. Specify its type based on the database you have in mind and enter the host details.
If you have a database in the same namespace (Cloud Container project), you can use its name and port in this field. For example: postgres:5432
Then enter the username and password of the database you want connected to Gogs, and the name of the related database.
Also, in the Domain and Application URL fields in Application General Settings, replace localhost with your application's domain name or dedicated IP.
Make sure to remove port 3000 from the Application URL field and change the protocol to HTTPS.
Finally, open the Admin Account Settings section at the end of the page and create an admin account.
Now click Install Gogs to enter Gogs.
In this environment, like GitLab, you can create repositories, share them with your colleagues, and manage your code.
For more details about Gogs, you can use its guide.