mirror of
https://github.com/kubevela/kubevela.git
synced 2026-02-14 18:10:21 +00:00
1.8 KiB
1.8 KiB
Deploying Application
vela app init
The simplest way to deploy an application with KubeVela is using $ vela app init .
$ vela app init
Check the application:
$ vela app show myapp
About:
Name: myapp
Created at: 2020-09-18 22:42:04.191171 +0800 CST
Updated at: 2020-09-18 22:51:11.128997 +0800 CST
Environment:
Namespace: demo
Components:
Name Type Traits
frontend webservice route
Check the deployed service:
$ vela svc show mycomp
About:
Name: frontend
WorkloadType: webservice
Application: myapp
Environment:
Namespace: demo
Arguments:
image: crccheck/hello-world
name: frontend
port: 8000
Traits:
route:
domain: frontend.kubevela.demo
issuer: oam-env-demo
name: route
Deploy Application Step by Step
You can also use KubeVela CLI to deploy a more complex micro-services application step by step, with detailed configurations.
Check the available workload types.
$ vela workloads
TODO
Deploy the first service named frontend with Web Service type.
$ vela svc deploy frontend -t webservice --image crccheck/hello-world --app myapp
Creating frontend ...
SUCCEED
TODO auto generate a random application name, so --app myapp becomes optional
Deploy the second service named backend with "Backend Worker" type for the same application.
$ vela svc deploy backend -t backendworker --image crccheck/hello-world --app myapp
Creating backend
SUCCEED
$ vela svc ls
NAME APP WORKLOAD TRAITS STATUS CREATED-TIME
backend myapp backendworker Deployed 2020-09-18 22:42:04 +0800 CST
frontend myapp webservice Deployed 2020-09-18 22:42:04 +0800 CST