Create a Virtual Site
On This Page:
Objective
This guide provides instructions on how to create a virtual site by assigning labels. A virtual site provides a mechanism to perform operations on a group of sites, reducing the need to repeat the same set of operations for each site. To learn more about virtual sites and labels, see Virtual Site and Labels, respectively.
You can use virtual sites to deploy applications, discover service endpoints, and advertise services across a number of sites selected per the site selection criteria of the virtual site.
Using the instructions provided in this guide, you can assign labels to your sites and group them together to create a virtual site.
Prerequisites
-
An F5® Distributed Cloud Services Account. If you do not have an account, see Create an Account.
-
A registered site in the enterprise tenant. If you do not have a registered site, see Site Management.
Configuration
The following shows a label assignment and creation of a virtual site workflow:
Configuration Sequence
Creating a virtual site includes performing the following sequence of actions:
Phase | Description |
---|---|
Create and Assign a Custom Label | Create a new label or use an existing label to assign it to a site. |
Create a Virtual Site | Create a virtual site using the label expression. The label created in the previous phase is used to match the site and group it under the virtual site. |
Note: The keys and labels can be provided by the system or can be user-defined. For more information on labels, see Labels.
Create and Assign a Custom Label
Perform these steps to create and assign a custom virtual site label:
Step 1: Navigate to the list of sites.
- Log into F5® Distributed Cloud Console (Console) and click
Cloud and Edge Sites
.
-
Find your site and then click
...
. -
Click
Manage Configuration
.
- Click
Edit Configuration
.
Step 2: Enter a value for the corresponding key created in Step 1.
-
Navigate to the
Labels
field. -
Select
Add label
.
-
Select a pre-defined key.
-
Click
Save and Exit
.
Step 3: View the newly applied label.
-
Navigate to your site from
Site List
and expand the metadata JSON section. -
Expand
"labels"
to view the newly applied site label.
Note: The
"metadata"
field contains all labels associated with your site. As sites are registered, Distributed Cloud Services automatically populates some labels, such ashw-vendor
,provider
,hw-model
, etc. You can determine the existing labels assigned to your site by checking the site schema from Console or using APIs.
Create a Virtual Site
Note: The steps below show how to create a virtual site in the
Distributed Apps
service. This option limits the virtual site to a specific namespace. You can also create a virtual site in theShared Configuration
service. With theShared Configuration
service option, multiple site objects across different namespaces can use the same virtual site and be grouped together.
Step 1: Start creating the virtual site.
- In Console, click
Distributed Apps
.
-
Navigate to your desired namespace.
-
Click
Manage
>Virtual Sites
. -
Click
Add Virtual Site
to load the creation form.
Step 2: Enter the required information.
-
In the
Metadata
sectionName
field, enter a virtual site name. -
In the
Site Type
section, select a site type from the drop-down menu.
Step 3: Frame the label expressions to group sites.
- From the
Selector Expression
field, clickAdd label
.
- Select the label expression.
Step 4: Complete creating virtual site.
Click Save and Exit
.