Feedback

Chat Icon

End-to-End Kubernetes with Rancher, RKE2, K3s, Fleet, Longhorn, and NeuVector

The full journey from nothing to production

Deploying and Managing Workloads Using Rancher Manager - Part I
28%

Deploying Gitea with Rancher Manager

Later in this guide, we are going to need a Git server, therefore, since we are in the process of tooling up our environment, and understanding how to deploy applications using Rancher Manager, we are going to deploy Gitea.

ℹ️ Gitea is a self-hosted Git service that is easy to deploy and manage.

We are going to deploy it in the tools project we created earlier. Note that we are always deploying applications in the same local cluster where Rancher Manager is running. In a production environment, you would deploy this application in a different environment.

To deploy Gitea, we are going to use the official Helm chart. Repeat the same steps we used to deploy Harbor but this time for Gitea:

  • Create a namespace called gitea in the tools project.
  • Add a new repository for the Gitea Helm chart. Use https://dl.gitea.io/charts/ as the Index URL.
  • From Apps > Charts, search for gitea
  • Choose the version 12.4.0 of the chart
  • Install it in the gitea namespace with the release name gitea.

These are the values we are going to change in the values.yaml file:

  • admin.email: Change the email address.
  • admin.password: Change the password.
  • ingress.enabled: Enable the ingress controller (true).
  • ingress.hosts.host: Change the host to gitea.$WORKSPACE_PUBLIC_IP.sslip.io.
  • ingress.className: Change the ingress class to traefik.
  • image.tag: Change the image tag to a static version, for example, 1.24.
  • image.rootless: Set to false. It seems that rootless mode image is not available at the time of writing this guide but you can try to set it to true and test it.
  • postgresql.enabled: Enable standalone PostgreSQL.
  • postgresql-ha.enabled: Disable PostgreSQL HA.
  • valkey.enabled: Enable standalone Valkey.
  • valkey-cluster.enabled: Disable Valkey cluster.
  • service.ssh.port: Change the port to 2222.
  • And other configurations as needed.

You can also choose between a regular PostgreSQL database or a PostgreSQL HA setup. We are going to use the regular setup as we don't have a need for high availability. Same for Valkey, we are going to disable the cluster and enable the standalone setup. The cluster setup is useful for high availability.

We will keep the default values for PostgreSQL and Valkey passwords but these values as well as many others should be changed in a production environment. Refer to the Gitea Helm chart documentation for more information.

All changes are summarized below:

[...]

gitea:
  admin:
    # Change the email address
    email: [CHANGE_ME]
    # Change the password
    password: p@ssword
    # This is the default username
    # We can keep it as is
    username: gitea_admin

[...]

image:
  repository: gitea
  # Make sure to use a static version
  # better than `latest`
  tag: '1.24'
  rootless: false


[...]

ingress:
  # Use the Traefik ingress controller (default for Rancher)
  className: traefik
  # Enable the ingress controller
  enabled: true
  hosts:
    # change $WORKSPACE_PUBLIC_IP
    - host: gitea.$WORKSPACE_PUBLIC_IP.sslip.io

[...]

postgresql:
  # Enable standalone PostgreSQL
  enabled: true

[...]

postgresql-ha

End-to-End Kubernetes with Rancher, RKE2, K3s, Fleet, Longhorn, and NeuVector

The full journey from nothing to production

Enroll now to unlock all content and receive all future updates for free.