This topic compares the volume settings and the environment variable settings used in a Swarm cluster with those used in a Kubernetes cluster for creating an application through an image.

Create an application by using an image

If you create an application in the Container Service console by using an image, the Swarm cluster Web interface is different from the Kubernetes cluster Web interface.

Set a volume

Container Service Swarm clusters

Specify your cloud or local storage path.

Container Service Kubernetes clusters

In Container Service, storage devices can be used in the same way in both Kubernetes and Swarm clusters, which have basically the same cluster console interface settings. However, the storage devices are mounted with different methods in these two types of clusters.

You can use either a local storage device or a cloud storage device.

  • Available local storage types include HostPath, ConfigMap, Secret, and EmptyDir.
  • Available cloud storage types include cloud disk, NAS, and OSS.

Set environment variables

The Environment parameter can be set with the same method for Swarm clusters and Kubernetes clusters. You only need to specify keys and their corresponding values.