# Setting up CDN Video Streaming with EOS ## E2E Object Storages E2E Object Store (EOS) is a simple, cost-effective, and S3-compatible storage service that enables you to store, backup, and archive large amounts of content for your web apps or data for AI/ML pipelines. Our S3 Compatible REST API enables data access from anywhere on the internet or within your private network. EOS is designed to handle large data volumes so you can scale as per your needs. Under the hood, it is a distributed object storage, a federation of large clusters that ensure high availability. Erasure coding, the standard practice for data storage, is employed for redundancy and fault tolerance. ## Getting Started In EOS, data files are organized in the form of objects in a bucket. A bucket is a container just like folders or directories in your OS and allows separation of concerns. For example, you could create a bucket for a personnel app and another one for an accounts app. This enables you to manage permissions and data separately. To start using EOS for data storage, you must create a bucket. ## How to Create a Bucket ### Logging into E2E Networks MyAccount 1. Go to My Account and log in using your credentials set up at the time of creating and activating the E2E Networks My Account. 2. Sign into My Account. 3. Navigate to `Products > Storage` in the sidebar menu. 4. Click on the `+ Add bucket` button. ![Bucket Creation](./images/cdnv1.png) - Enter a unique bucket name. Guidelines: - Name must be unique across all existing buckets in E2E Object Storage. - Must be between 3 and 63 characters. - No uppercase letters or underscores. - Should not be formatted like an IP address (e.g., `10.10.10.2`). - Click `Create`. - You will be redirected to the object browser. ![Object Browser](./images/cdnv2.png) ## Storage Browser The storage browser acts as a primary control center for your content. It supports bucket creation, permission handling, and object upload/download. Visit the [My Account Storage Browser](http://myaccount.e2enetworks.com/storage/browser). ![Storage Browser](./images/cdnv3.png) ## Bucket Details 1. Log in to My Account. 2. Navigate to `Products > Storage`. 3. Choose a bucket or create a new one. 4. Click the `Object browser` tab to browse or manage bucket permissions. 5. Click the `Bucket details` tab to view bucket-related information. ## Public Access Permissions ![Bucket Permissions 1](./images/cdnv4.png) ![Bucket Permissions 2](./images/cdnv5.png) In EOS, you need to grant access permission for storage buckets. These permission settings apply only to this bucket and its associated stored objects. ### Bucket Permissions for CLI/API Access To use CLI or API for accessing data on EOS, define bucket permissions. ## Create Access Key ![Create Access Key](./images/cdnv6.png) 1. Enter a name for your access key (e.g., project or team member name). 2. Click `Generate Key`. 3. Note both access and secret keys (they won't be visible again after closing the modal). 4. Use the command provided to configure CLI with this access key if using `mc`. ## Manage Access To disable access for specific users or applications: ![Manage Access](./images/cdnv7.png) 1. Navigate to `Products > Storage`. 2. Click `Manage Access Key`. 3. Identify and lock/unlock the access key as needed. ## Working with CLI ### Download MinIO Client - **Linux (64-bit Intel)**: [Download](https://dl.min.io/client/mc/release/linux-amd64/mc) - **Linux (64-bit PPC)**: [Download](https://dl.min.io/client/mc/release/linux-ppc64le/mc) - **Windows (64-bit)**: [Download](https://dl.min.io/client/mc/release/windows-amd64/mc.exe) - **MacOS**: `brew install minio/stable/mc` For other methods, visit [MinIO documentation](https://docs.min.io). ### Adding Picture in Bucket using CLI Generate or create an access key and use the provided `mc config` command: ```bash mc config host add https://objectstore.e2enetworks.net ``` Minio CLI Configurations ```bash mc config host add e2enetworks https://objectstore.e2enetworks.net ``` ![](images/cdnv8.jpg) ## View Object Content Use cat command to view contents of objects in your bucket. You can also use head command to display top few lines of an object. ```bash is accesskey name. is bucket name ``` You can copy content from local system to object store using cp command. The copy operations to object store are verified with MD5SUM checksums. Interrupted or failed attempts can be resumed from the point of failure. ```bash is accesskey name. is bucket name ``` ![](images/cdnv9.png) !Remove Content Use rm command to delete file or object. ```bash is accesskey name. is bucket name ``` ![](images/cdnv10.png) ## Uploading Videos to Bucket Storage and attaching with CDN * Please go to My Account and log in using your credentials set up at the time of creating and activating the E2E Networks My Account. * Sign into My Account * Go to Products > Storage option in sidebar menu * Click on Upload button ![](images/cdnv11.png) ### Uploading objects in EOS ![](images/cdnv12.png) * After Uploading video it can be accessed by url: ``` https://e2enetworks.objectstore.e2enetworks.net/LB/LB-Node.mp4 /File -directory> ``` ## Creating CDN E2E CDN is a fast content delivery network (CDN) service that securely delivers data, and static contents to customers globally with low latency, high transfer speeds. The idea of a CDN is essentially to have multiple edges in different locations of the world which caches all the static content so that it can be delivered from the customer’s closest location. We intend to integrate CDN such that people hosting applications through us can use CDNs to improve their static asset delivery. With E2E’s CDN, you can take the initial steps to speed up the delivery of your static content (for example images, JavaScripts, Style Sheets, and many others). With E2E CDN, you can guarantee your viewers a fast, reliable, and safe experience across the globe. To create CDN with E2E. * Navigate to the CDN page on MyAccount * On the left side of the My Account dashboard, click on the “CDN” sub-menu available under the “Services” section. ![](images/cdnv13.png) * Click on the “Create CDN” button. You will be redirected to the “Create Content Delivery Network” page. ![](images/cdnv14.png) * Here, you need to specify the ‘Origin Domain Name’, ‘Origin Path’, and ‘Origin ID’. 1. **Origin Domain Name**: Enter the “Origin Domain Nameâ€. For example, xyz.abc.com / abc.com. It is the DNS domain name of the HTTP Server or E2E Object storage bucket from which your static content gets delivered. For example, xyz.abc.com / abc.com. The files in your origin must be publicly readable. E2E CDN will contact this origin for the content requested by the user if not found on the CDN edge server cache. 2. **Origin Path**: Enter the “Origin Path†beginning with /. For example, xyz.com/static. Do not include / at the end of the directory name. It is the path of the folder or directory from where the content should be delivered. CDN appends the directory name to the value of Origin Domain Name when forwarding the request to the origin. If the content from this directory fails, CDN will give a “Not Found†response to the user. 3. **Origin ID**: Enter a description for the “Origin Pathâ€. This value lets you distinguish multiple origins in the same distribution from one another. The description for each origin must be unique within the distribution. Currently, you can add only a single origin for a distribution. 4. **SSL Certificate**: **Default SSL Certificate (*.e2enetworks.net)** Choose this option if you want your users to use HTTPS or HTTP to access your content with the E2E Networks domain name (such as https://example.cdn.e2enetworks.net/logo.jpg) Important: if you choose this option, it requires that browsers or devices support TLSv1 or later to access your content. **Custom Certificate (example.com)** Choose this option if you want your users to access your content by using an alternate domain name, such as https://www.example.com/logo.jpg. If you want to use a custom certificate then you need to specify the CNAMEs separated with commas or put each on a new line. .. Note:: Origin Domain and Alternate Domain Names(CNAMEs)(if any provided) should have the same domain names. All the Alternate Domain Names(CNAMEs) on the CDN should be covered by the Subject Alternative Name (SAN) of the certificate. ![](images/Create_CDN_info_filled_page.png) * After specifying the above value, click on the Create Distribution button. You will automatically redirect to the CDN Services page and a confirmation message will appear on the screen. ![](images/4.png) :::info Note After the creation of CDN distribution, it will take up to 30 minutes to deploy the configuration changes on the CDN Edge servers. ::: ```bash CDN URL e2enetworksn3dd0rlzwd.cdn.e2enetworks.net/LB/LB-Node.mp4 ``` ## Manage/Update CDN settings There are 5 types of settings that a user can check and update for any CDN: ## Basic Details In the Basic detail tab, you will get to the general information about your CDN which are the default settings and you specify during the creation/updation of the CDN. Click on the Edit button to update the basic setting of your distribution. ![](images/cdnv15.png) ---