UCloud logo UCloud logo UCloud
v2025.1.0
  1. UCloud/Core
  2. 1. Introduction
  3. 2. Projects
  4. 3. Accounting
  5. 4. Orchestration
  6. UCloud/IM for Slurm-based HPC
  7. 5. Installation
  8. 6. Architecture and Networking
  9. 7. User and Project Management
  10. 8. Filesystem Integration
    1. 8.1. Inter-provider file transfers
  11. 9. Slurm Integration
    1. 9.1. Application Management
    2. 9.2. Built-in Applications
  12. 10. Reference
    1. 10.1. Configuration
    2. 10.2. CLI
  13. 11. Appendix
    1. 11.1. Built-in Application Index
  14. UCloud/IM for Kubernetes
  15. 12. Installation
  16. 13. Architecture and Networking
  17. 14. Filesystem Integration
  18. 15. Compute Jobs
    1. 15.1. Public Links
    2. 15.2. Public IPs
    3. 15.3. License Servers
    4. 15.4. SSH Servers
  19. 16. Integrated applications
    1. 16.1. Syncthing
    2. 16.2. Integrated terminal
  20. 17. Reference
    1. 17.1. Configuration
  21. H: Procedures
  22. 18. H: Procedures
  23. 19. H: Introduction
  24. 20. H: Auditing
  25. 21. H: Auditing scenario
  26. 22. H: GitHub actions
  27. 23. H: Deployment
  28. 24. H: 3rd party dependencies (risk assesment)
  1. Links
  2. Source Code
  3. Releases

Installation

This document will guide you through the process of obtaining and installing UCloud/IM for Kubernetes. By the end of this document you will be connected to UCloud’s sandbox environment.

Prerequisites

The UCloud Integration Module should be deployed on Kubernetes cluster running on a node, which does not run any user-jobs. We recommend that the Integration Module itself has the following minimum requirements available to it:

  • OS: Linux (any distribution)
  • CPU: x86_64 with at least 8 vCPU
  • Memory: 32GB

Cluster minimum requirements:

  • Kubernetes: UCloud supports the most recent three minor releases of Kubernetes. See the Kubernetes release history for more information.
  • Filesystem: A distributed filesystem exposing a standard POSIX interface.
  • K8s Networking: UCloud does not depend on non-standard K8s networking. It is actively developed and tested against Cilium.

In addition, the integration module must be deployed in a namespace which allows:

  • Must allow inbound and outbound Internet connectivity
  • Must have at least one node which should accept UCloud jobs

Obtaining the Software

UCloud/IM for Kubernetes can be installed using Helm. You can use the following commands to install it.

$ helm repo add sdu-escience https://sdu-escience.github.io/charts
$ helm repo update
$ helm show values sdu-escience/ucloud-im > values.yaml

# NOTE: At this point you MUST modify the values (see below)

$ helm install ucloud-im \
    sdu-escience/ucloud-im \
    --namespace ucloud-im \
    -f values.yaml

There are some prerequisites that must be manually configured before using the Helm chart to install UCloud/IM.

  • Two namespaces must exist, one for running the UCloud/IM software and one for running all the user jobs. In the following example we call these two namespaces ucloud-im and ucloud-apps respectively.
  • Both namespaces must have a PersistentVolumeClaim with the same name, pointing to the same shared storage. This shared storage is used for storing user data. The volume must be configured with accessMode set to ReadWriteMany.

The following is an example of Kubernetes manifests that create the two namespaces and the required volumes. Here we assume that there is a shared filesystem mounted on all nodes and we can simply access this via the HostPath option. Adjust this based on the local storage system and installed CSI provisioners.

apiVersion: v1
kind: Namespace
metadata:
  name: ucloud-im
---
apiVersion: v1
kind: PersistentVolume
metadata:
  name: ucloud-im-user-data
spec:
  storageClassName: manual
  capacity:
    storage: 1Ti
  accessModes:
    - ReadWriteMany
  hostPath:
    path: /example/path
    type: Directory
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: ucloud-user-data
  namespace: ucloud-im
spec:
  volumeName: ucloud-im-user-data
  storageClassName: manual
  accessModes:
    - ReadWriteMany
  resources:
    requests:
      storage: 1Ti
apiVersion: v1
kind: Namespace
metadata:
  name: ucloud-apps
---
apiVersion: v1
kind: PersistentVolume
metadata:
  name: ucloud-apps-user-data
spec:
  storageClassName: manual
  capacity:
    storage: 1Ti
  accessModes:
    - ReadWriteMany
  hostPath:
    path: /example/path
    type: Directory
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: ucloud-user-data
  namespace: ucloud-apps
spec:
  volumeName: ucloud-apps-user-data
  storageClassName: manual
  accessModes:
    - ReadWriteMany
  resources:
    requests:
      storage: 1Ti

Chart configuration

The following is a minimal example of a Helm values file that can be used for installing UCloud/IM. For a full list of all configuration options, see the next section.

serviceAccount:
  create: true

ingress:
  enabled: true
  hosts:
    - "example.com"
    - "*.example.com"

provider:
  storage:
    size: 1Gi
    storageClass: example

apps:
  namespace: ucloud-apps
  storage:
    existingClaim: ucloud-user-data

Some general comments about the configuration.

  • UCloud/IM requires a service account with permissions to manage user jobs in the ucloud-apps namespace. This service account, including the required RBAC rules, is automatically created when serviceAccount.create is enabled.

  • UCloud/IM requires some storage for the provider configuration. A volume can automatically be provisioned, as in the example above, or you can provide an existingClaim to use an existing volume. Be aware that the volume used for the configuration files cannot be the same volume used for the user data.

  • UCloud/IM must be accessible via https on a public address. An ingress resource can automatically be provisioned.

  • Finally, some configuration is needed for the user jobs. In the apps section we specify the namespace for running user jobs and the name of an existing volume for storing user data.

Use the following Helm command for installing the software.

$ helm install myrelease ./ucloud-im -n ucloud-im -f values.yaml

Helm Values

Reference for all available Helm values.

NameDescriptionValue
serviceAccount.createSpecifies whether a ServiceAccount should be createdtrue
serviceAccount.annotationsAdditional custom annotations for the ServiceAccount{}
serviceAccount.nameThe name of the ServiceAccount to use""
netpol.enabledCreate network policies for the deploymentstrue
netpol.ingress.http.allowedAllow ingress traffic to the http endpointtrue
netpol.ingress.http.namespaceAllow only ingress traffic to the http endpoint from this namespace""
netpol.ingress.metrics.allowedAllow ingress traffic to the metrics endpointtrue
netpol.ingress.metrics.namespaceAllow only ingress traffic to the metrics endpoint from this namespace""
ingress.enabledSpecifies whether an Ingress should be createdfalse
ingress.annotationsAdditional custom annotations for the Ingress{}
ingress.hostsList of hosts used for the Ingress[]
ingress.tlsTLS configuration the Ingress[]
provider.revisionHistoryLimitThe number of retained replica sets to allow rollback2
provider.nodeSelectorNode selector labels for provider pods{}
provider.annotationsAnnotations for provider pods{}
provider.tolerationsTolerations for provider pods[]
provider.affinityAffinity for provider pods{}
provider.strategyTypeStrategy type for replacing provider pods""
provider.commandOverrride the command for the provider container["/usr/bin/ucloud"]
provider.storage.sizePersistent Volume size1Gi
provider.storage.storageClassPersistent Volume storage class""
provider.storage.accessModesPersistent Volume access modes["ReadWriteMany"]
provider.storage.existingClaimUse an existing PVC which must be created beforehand""
provider.storage.subPathThe subdirectory of the volume to mount in the containers""
provider.storage.selectorAdditional labels to match for the PVC{}
provider.storage.dataSourceCustom data source for the PVC{}
provider.image.repositoryProvider image repositorydreg.cloud.sdu.dk/ucloud/im2
provider.image.pullPolicyProvider image pull policyIfNotPresent
provider.image.tagProvider image tag""
provider.service.typeProvider service typeClusterIP
provider.service.annotationsProvider service annotations{}
envoy.revisionHistoryLimitThe number of retained replica sets to allow rollback2
envoy.nodeSelectorNode selector labels for envoy pods{}
envoy.annotationsAnnotations for envoy pods{}
envoy.tolerationsTolerations for envoy pods[]
envoy.affinityAffinity for envoy pods{}
envoy.strategyTypeStrategy type for replacing envoy pods""
envoy.image.repositoryEnvoy image repositoryenvoyproxy/envoy
envoy.image.pullPolicyEnvoy image pull policyIfNotPresent
envoy.image.tagEnvoy image tagv1.23-latest
envoy.service.typeEnvoy service typeClusterIP
envoy.service.annotationsEnvoy service annotations{}
apps.namespaceNamespace for running user jobsucloud-apps
apps.storage.existingClaimUse an existing PVC which must be created beforehand""
apps.storage.subPathThe subdirectory of the volume to mount in the containers""
apps.netpol.enabledCreate network policies for the apps namespacetrue
apps.netpol.egress.allowedAllow egress traffic from the apps namespacetrue
apps.netpol.egress.blockPrivateBlock egress traffic to private IPv4 subnetstrue
apps.netpol.egress.toRulesCustom rules for allowing egress traffic[]

Registering as a Provider

This section will create a secret file containing your credentials. By default, it will be located at /etc/ucloud/server.yml. Please keep this file safe and keep a backup of it. In case of a re-installation, you should aim to re-use this file.

Before you can start UCloud/IM, you must register as a service provider. This only needs to be done once. You may receive a test provider in UCloud’s sandbox environment by contacting the support team.

Once the registration is complete, you now have a provider on UCloud’s sandbox environment. From the UCloud interface, you should now be able to select your provider project from the project switcher. You can add other UCloud users to help manage your provider by inviting them through the interface. See the end-user documentation for more details.

You will be able to manage parts of your provider through UCloud’s interface. To do this, you must first select the provider project which you are automatically added to.

Previous Built-in Application Index
Next Architecture and Networking