There are two ways to create a new property:
After you create the new property, save and validate the property before you deploy and test it.
Fields | Description |
---|---|
Property Name | Enter a name that helps you identify this property. |
Description | Add a description to associate with this property. |
Configuration Version | Read-only field that shows the version number of this property. By default, your first property configuration is Version 1. |
Description | Add a description for this first property version. |
Hostnames | Enter one or more hostnames to be accelerated and which your end users will access. |
Origins | Origins are your servers that CDN Pro accesses to fetch your content. You can specify more than one server. Click the Add New link and then see Adding or Editing Origins in a Property. |
Edge Logic | Write NGINX configuration code to specify how you want CDN Pro to deliver content to your visitors. You can click the Wizard button to bootstrap this configuration using the Edge Logic Wizard dialog box. For more information, refer to CDNetworks' Edge Logic documentation, which includes a description of supported directives. |
TLS Settings | Select the TLS client certificate settings for your property. |
Real Time Logging | If this advanced feature was enabled for you, complete the real-time logging parameters. If you require this feature, contact the CDNetworks support team. |
Advanced Settings | Use advanced settings to specify cache sharing, China ICP Beian, and a load balancer hash key. |
Note: If you add a baseline configuration, the wizard appends its configuration after that of the baseline configuration. When you save the baseline configuration, it will not be used to initialize the Edge Logic until you create another property. To use the baseline configuration with the current property you are adding or editing, reload the page; doing so, however, may cause you to lose other changes you made.
To save the property, click the Save button. Several basic syntax checks are performed. If errors are found, you are prompted to fix them before the property is saved. Any property version will have to be "validated" before it can be deployed to staging or production. You can click the Save & Validate button to start the validation process. When the Confirmation pop-up appears, click OK. The validation process usually takes less than a minute. You can either wait for it to finish or close the progress dialog box to perform other tasks while validation continues in the background. You can click Tasks in the left pane to check the validation results. If there is a failure, perform the instructions in the error message to fix it.
If the property is validated successfully, you can deploy it to the staging or production environment. By default, trial users will have access to the staging environment only. Please contact the CDNetworks support team to enable access to the production environment.
Use the Edge Logic wizard to create an initial version of the Edge Logic. The wizard supports some of the most basic cache configurations. You can set cache behavior for multiple locations. You can also modify the generated Edge Logic code to add complicated behaviors to suit your requirements.
When you click the Wizard button, a prompt appears with the following choices.
After making your selection, complete the settings in the Edge Logic Wizard page, and then click OK to display the Edge Logic code. You can then edit the code shown in the field as necessary or click the Wizard button to change your selections.
Note: If the Edge Logic code is extremely long, check the Soft Wrap Text check box to display long text on multiple lines instead of one long line.
This section allows you to:
Note: If you enter multiple cipher suites in the TLS Ciphers field, separate them with colons.
If you signed an agreement with CDNetworks for accessing the real-time log, use the Real-Time Log section to "stream" an access log in real time to your designated HTTP or HTTPS endpoint. You can specify the format of each log entry using the NGINX variables shown in the following table; they will be replaced with the actual values in the notifications. If you use JSON format for the log, select JSON to escape special characters in the variable values. You can also specify a sample rate to reduce the number of log entries. Use request headers to pass additional information to the receiving endpoint.
Variable | Description |
---|---|
$body_bytes_sent | Size of the response body. |
$bytes_sent | Size of the response, including body, headers, and response line. |
$client_country_code | ISO 3166-1 country code representing the country of the client request (for example, US). If the country is unknown, ZZ is returned. |
$client_real_ip | IP address of the client request. |
$content_code | A code assigned to content for reporting and billing purposes. |
$cookie_x | Obtains any cookie named x. For example, $cookie_account retrieves the value of a cookie named account. |
$http_x | Obtains any HTTP header named x from the original request. The header name is converted to lower case, with dashes replaced by underscores. For example, $http_user_agent fetches the value of User-Agent. |
$msec | Current Unix time in seconds with millisecond precision. |
$qtl_req_id | Unique identifier representing the request. |
$request_uri | HTTP request URI. |
$request_method | HTTP request method used to access the origin. |
$request_scheme | Protocol of the user's request (either http or https). |
$request_time | Response time in milliseconds. This is the time between receiving the request's first byte and serving the last byte of the response. |
$sc_completed | 1 = last byte of the object was served to the user. Otherwise, 0. |
$sc_initial | 1 = first byte of the object was served to the user. Otherwise, 0. |
$sent_http_content_length | Original file size. |
$sent_http_x | Obtain the value of an HTTP header named x that is returned in the response to the client. The header name is converted to lower case, with dashes replaced by underscores. For example, $sent_http_etag fetches the value of the ETag header. |
$server_addr | IP address of the edge node serving the user's request. |
$server_protocol | Version of HTTP used in the user's request (HTTP/1.0, HTTP/1.1, or HTTP/2.0). |
$ssl_cipher | Cipher suite used for the TLS (SSL) connection. |
$ssl_server_name | Hostname to which a client initiating a TLS (SSL) connection is attempting to connect. It is sent only by clients supporting Server Name Indication (SNI). |
$ssl_protocol | TLS version used for the TLS (SSL) connection. Example versions include SSLv3, TLSv1, TLSv1.1, TLSv1.2, and unknown. |
$status | HTTP response code for the user's request. |
$tcpinfo_rtt | Time in microseconds taken by a packet to travel to the destination and return. |
Cache Key Hostname: By default, the Host header value in the client request is used in the cache key. If this property contains multiple service hostnames, the contents of different hostnames will be cached separately. If you want all hostnames to share one cached copy, specify a fixed "Cache Key Hostname" to override the default behavior.
Has ICP Beian: If this property must be served from servers in mainland China, make sure all hostnames have Beian on file with the Chinese government. You can then contact the CDNetworks support team to enable this function for you. Once enabled, change the Has ICP Beian setting to Yes.
Note: You can set Has ICP Beian to Yes without contacting CDNetworks; however, the functionality WILL NOT be enabled until you request activation from CDNetworks.
Note: Setting Has ICP Beian to Yes applies to the entire property, i.e. all hostnames in a property. If any hostname in a property does not have Beian, the property deployment will be rejected. And, if any hostname in a deployed property is later found to have invalid Beian, CDN Pro will automatically turn off the "hasBeian" switch for the entire property, even if the other hostnames in the same property still have valid Beian. Refer to this FAQ for more information.
Load Balancer Logic: Enter Edge Logic to customize load balancing. You can use a subset of the directives, including if
, set
, return
, eval_func
, add_header
, client_max_body_size
, deny
, and allow
. For the list of directives allowed in this field, refer to the loadBalancerDirectives
field in the response to the system configuration API. This list can include advanced Edge Logic directives that have not been enabled for your account.
Example: if ($http_user_agent = bot) { return 403;}
Note: If the Edge Logic code is extremely long, check the Soft Wrap Text check box to display long text on multiple lines instead of one long line.
Load Balancer Hash Key: CDN Pro uses multiple tiers of load balancing to distribute client requests to different servers, with consistent hashing used in many of these places. By default, the URL is used as the hash key, which should be satisfactory in most cases. However, you can define additional variables to be added to the hash key to distribute the requests more evenly. One typical use case is when all requests carry the same URL, but use a particular header field to indicate different resources. In general, the variable(s) specified here should be a subset of the variables you enter into the cache key. Only the following variables are supported: $http_*
, $cookie_*
, $arg_*
.
Certificate Renew Automation: By default, CDN Pro takes control of the contents under the /.well-known/{acme-challenge, pki-validation}
directories to support certificate auto-renew for properties. If you need to manage these two directories by yourself on the origin (for example, to implement your own certificate auto-renew mechanism), you can use this configuration option to disable the default behavior.
HTTP/2: Use the radio buttons to enable or disable the HTTP/2 protocol. HTTP/2 is enabled by default. If disabled, HTTP/1.1 is used.
HTTP/3: Use the radio buttons to enable or disable the HTTP/3 protocol. HTTP/3 is disabled by default.
Video Seeking: This parameter supports seeking in a video using the following fields to specify the starting and ending positions.