Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
layout: post
title: Deploy Syncfusion Word Processor in Amazon Kubernetes Service
description: Learn here all about How to deploy word processor server docker container in amazon kubernetes service in Syncfusion React Document editor.
description: Learn here all about How to deploy word processor server docker container in Amazon Kubernetes Service in the Syncfusion React Document Editor.
control: How to deploy word processor server docker container in amazon kubernetes service
platform: document-processing
documentation: ug
Expand All @@ -11,28 +11,28 @@ domainurl: ##DomainURL##

## Prerequisites

* `AWS Account` :Have Amazon account
* `AWS Account`: Have an Amazon account.
* `AWS CLI`: Install the AWS Command Line Interface (CLI) on your local machine.
* `Kubectl` : Install the Kubernetes command-line tool kubectl on your local machine.
* `Kubectl`: Install the Kubernetes command-line tool kubectl on your local machine.
* `Docker`: Install Docker on your local machine.
* `Word Processor Docker Image`: Have a Docker image of the Word Processor server ready to deploy.

To deploy the Word Processor server docker image, need to follow the below process
To deploy the Word Processor server docker image, you need to follow the process below.

* Push Docker Image to Registry (Amazon Elastic Registry)
* Deploy Docker Image on Amazon Kubernetes Service

Lets us discuss briefly about the each process
Let us briefly discuss each process.

## Push the Docker image to the Amazon Elastic Registry

**Step 1:** Dockerize the Word Processor Server Application with the image name [syncfusion/word-processor-server](https://hub.docker.com/r/syncfusion/word-processor-server)

```
docker build -t <your-image-name>
docker build -t <your-image-name> .
```

**Step 2:** Create a private repository name ‘documenteditor in Amazon Elastic Container Registry (ECR) using the AWS CLI or AWS Console to push the docker image
**Step 2:** Create a private repository named 'documenteditor' in Amazon Elastic Container Registry (ECR) using the AWS CLI or AWS Console.

```
aws ecr create-repository --repository-name <repository-name>
Expand All @@ -43,13 +43,13 @@ aws ecr create-repository --repository-name <repository-name>
```
docker tag <your-image-name>:latest <your_ECR_registry_URI>/<your_repository_name>:latest
```
Refer to the following example to tag the image
Refer to the following example to tag the image.

```
docker tag syncfusion/word-processor-server:latest 123456.dkr.ecr.us-east-1.amazonaws.com/documenteditor:latest
```

> Get the ECR registry URI from AWS console or using the below AWS CLI command
N> Get the ECR registry URI from AWS console or using the below AWS CLI command.

```
aws ecr describe-repositories --repository-names <repository-name> --query 'repositories[*].repositoryUri' --output text
Expand All @@ -71,18 +71,18 @@ docker push <your_ECR_registry_URI>/<your_image_name>:latest

## Deploy Docker Image on Amazon Kubernetes Service

Follow the below steps to deploy the Docker image from the Amazon Elastic Registry( ECR) to Amazon Kubernetes Services (EKS)
Follow the below steps to deploy the Docker image from the Amazon Elastic Registry (ECR) to Amazon Kubernetes Services (EKS).

**Step 1:** DCreate Amazon EKS cluster using the AWS Console
**Step 1:** Create an Amazon EKS cluster using the AWS Console.

**Step 2:** Authenticate with AWS ECR
Need to get the authenticate with the AWS ECR to pull the image from the registry
**Step 2:** Authenticate with AWS ECR.
You need to authenticate with the AWS ECR to pull the image from the registry.

```
aws ecr get-login-password --region <your-region> | docker login --username AWS --password-stdin <your-aws-account-id>.dkr.ecr.<your-region>.amazonaws.com
```

**Step 3:** : Configure Kubernetes to Communicate with the Cluster
**Step 3:** Configure Kubernetes to communicate with the cluster.

```
aws eks --region <region> update-kubeconfig --name <cluster-name>
Expand All @@ -104,47 +104,47 @@ In this command:
* <your-region> should be replaced with your AWS region.


**Step 5:** To create Kubernetes deployment write Kubernetes manifest
**Step 5:** To create a Kubernetes deployment, write a Kubernetes manifest.

**i.** Create a Kubernetes Deployment manifest (deployment.yaml) for your application. Specify the Docker image location.

```
```yaml
apiVersion: apps/v1
kind: Deployment
metadata:
name: ```your-deployment```
name: your-deployment
spec:
replicas: 3
selector:
matchLabels:
app: ```your-app```
app: your-app
template:
metadata:
labels:
app: ```your-app```
app: your-app
spec:
containers:
- name: your-container
image: ```<account-id>.dkr.ecr.<region>.amazonaws.com/your-repository-name:tag```
image: <account-id>.dkr.ecr.<region>.amazonaws.com/your-repository-name:tag
ports:
- containerPort: 80
```
**ii.** Apply the Deployment manifest to create the deployment in your EKS cluster
**ii.** Apply the Deployment manifest to create the deployment in your EKS cluster.

```
kubectl apply -f deployment.yaml
```

**iii.** Use port forwarding to access the Word Processor Server application locally and verify its functionality
**iii.** Use port forwarding to access the Word Processor Server application locally and verify its functionality.

```
kubectl port-forward pod-name local-port:container-port
```

> Get the pod names in AWS Console or using the below AWS CLI command
N> Get the pod names in AWS Console or using the below AWS CLI command.

```
kubectl get pods
```

Finally you can get the sample in the localhost http://```<your-ip>```/api/documenteditor/
Finally, you can access the sample at localhost: http://<your-ip>/api/documenteditor/
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
---
layout: post
title: How to deploy word processor server docker container in azure app service in React Document editor component | Syncfusion
description: Learn here all about How to deploy word processor server docker container in azure app service in Syncfusion React Document editor component of Syncfusion Essential JS 2 and more.
control: How to deploy word processor server docker container in azure app service
title: How to deploy word processor server docker container in Azure App Service in React DOCX Editor | Syncfusion
description: Learn here all about How to deploy word processor server docker container in Azure App Service in the Syncfusion React DOCX Editor of Syncfusion Essential JS 2 and more.
control: How to deploy word processor server docker container in Azure App Service
platform: document-processing
documentation: ug
domainurl: ##DomainURL##
---
# How to deploy word processor server docker container in azure app service in React Document editor component
# How to deploy word processor server docker container in Azure App Service in React DOCX Editor

## Prerequisites

Expand All @@ -22,34 +22,34 @@ az login

Create a resource group using the [`az group create`](https://docs.microsoft.com/en-us/cli/azure/group#az-group-create) command.

The following example creates a resource group named documenteditorresourcegroup in the eastus location.
The following example creates a resource group named documenteditorresourcegroup in the East US location.

```
az group create --name documenteditorresourcegroup --location "East US"
```
```
az group create --name documenteditorresourcegroup --location "East US"
```

**Step 2:** Create an Azure App Service plan.

Create an App Service plan in the resource group with the [`az appservice plan create`](https://docs.microsoft.com/en-us/cli/azure/appservice/plan?view=azure-cli-latest#az-appservice-plan-create) command.

The following example creates an App Service plan named documenteditorappservice in the Standard pricing tier (--sku S1) and in a Linux container (--is-linux).

```
az appservice plan create --name documenteditorappservice --resource-group documenteditorresourcegroup --sku S1 --is-linux
```
```
az appservice plan create --name documenteditorappservice --resource-group documenteditorresourcegroup --sku S1 --is-linux
```

**Step 3:** Create a Docker Compose app.

Create a multi-container [`web app`](https://docs.microsoft.com/en-us/azure/app-service/containers/app-service-linux-intro) in the documenteditorappservice App Service plan with the [`az webapp create`](https://docs.microsoft.com/en-us/cli/azure/webapp?view=azure-cli-latest#az-webapp-create) command. The following command creates the web app using the provided Docker compose file. Please look into the section for getting started with Docker compose to create the Docker compose file for the document editor server and use the created Docker compose file here.
Create a multi-container [`web app`](https://docs.microsoft.com/en-us/azure/app-service/containers/app-service-linux-intro) in the documenteditorappservice App Service plan with the [`az webapp create`](https://docs.microsoft.com/en-us/cli/azure/webapp?view=azure-cli-latest#az-webapp-create) command. The following command creates the web app using the provided Docker Compose file. Refer to the Docker Compose getting started section to create the Docker Compose file for the document editor server and use the created Docker Compose file here.

```
az webapp create --resource-group documenteditorresourcegroup --plan documenteditorappservice --name documenteditor-server --multicontainer-config-type compose --multicontainer-config-file documenteditor-server-compose.yml
```
```
az webapp create --resource-group documenteditorresourcegroup --plan documenteditorappservice --name documenteditor-server --multicontainer-config-type compose --multicontainer-config-file documenteditor-server-compose.yml
```

**Step 4:** Browse to the app.

Browse to the deployed app at `http://<app_name>.azurewebsites.net`, i.e. `http://documenteditor-server.azurewebsites.net`. Browse this link and navigate to the Document Editor Web API control `http://documenteditor-server.azurewebsites.net/api/documenteditor`. It returns the default get method response.
Browse to the deployed app at `http://<app_name>.azurewebsites.net`, i.e., `http://documenteditor-server.azurewebsites.net`. Open this link and navigate to the Document Editor Web API control `http://documenteditor-server.azurewebsites.net/api/documenteditor`. It returns the default GET method response.

Append the app service running the URL `http://documenteditor-server.azurewebsites.net/api/documenteditor/` to the service URL in the client-side Document Editor control. For more information about the Document Editor control, refer to this [`getting started page`](../getting-started).
Append the app service running URL `http://documenteditor-server.azurewebsites.net/api/documenteditor/` to the service URL in the client-side Document Editor control. For more information about the Document Editor control, refer to this [`getting started page`](../getting-started).

For more information about the app container service, please look deeper into the [`Microsoft Azure Container Service`](https://docs.microsoft.com/en-us/azure/app-service/containers/quickstart-multi-container) for a production-ready setup.
For more information about the app container service, refer to the [`Azure App Service`](https://docs.microsoft.com/en-us/azure/app-service/containers/quickstart-multi-container) for a production-ready setup.
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
---
layout: post
title: How to deploy word processor server docker container in azure kubernetes service in React Document editor component | Syncfusion
description: Learn here all about How to deploy word processor server docker container in azure kubernetes service in Syncfusion React Document editor component of Syncfusion Essential JS 2 and more.
control: How to deploy word processor server docker container in azure kubernetes service
title: How to deploy word processor server docker container in Azure Kubernetes Service in React DOCX Editor | Syncfusion
description: Learn here all about How to deploy word processor server docker container in Azure Kubernetes Service in the Syncfusion React DOCX Editor of Syncfusion Essential JS 2 and more.
control: How to deploy word processor server docker container in Azure Kubernetes Service
platform: document-processing
documentation: ug
domainurl: ##DomainURL##
---
# How to deploy word processor server docker container in azure kubernetes service in React Document editor component
# How to deploy word processor server docker container in Azure Kubernetes Service in React Document editor component

## Prerequisites

Expand All @@ -22,51 +22,50 @@ az login

Create a resource group using the [`az group create`](https://docs.microsoft.com/en-us/cli/azure/group#az-group-create) command.

The following example creates a resource group named documenteditorresourcegroup in the eastus location.
The following example creates a resource group named documenteditorresourcegroup in the East US location.

```
az group create --name documenteditorresourcegroup --location "East US"
```
```
az group create --name documenteditorresourcegroup --location "East US"
```

**Step 2:** Create AKS cluster.

Use the [`az aks create`](https://docs.microsoft.com/en-us/cli/azure/aks?view=azure-cli-latest#az-aks-create) command to create an AKS cluster. The following example creates a cluster named documenteditorcluster with one node.

```
az aks create --resource-group documenteditorresourcegroup --name documenteditorcluster --node-count 1
```
```
az aks create --resource-group documenteditorresourcegroup --name documenteditorcluster --node-count 1
```

**Step 3:** Connect to the cluster.

Install the [`kubectl`](https://kubernetes.io/docs/reference/kubectl/kubectl/) into the workspace using the following command.
Install [`kubectl`](https://kubernetes.io/docs/reference/kubectl/kubectl/) using the following command.

```
az aks install-cli
```
```
az aks install-cli
```

To configure kubectl to connect to your Kubernetes cluster, use the [`az aks get-credentials`](https://docs.microsoft.com/en-us/cli/azure/aks?view=azure-cli-latest#az-aks-get-credentials) command. This command downloads credentials and configures the Kubernetes CLI to use them.

```
az aks get-credentials --resource-group documenteditorresourcegroup --name documenteditorcluster
```
```
az aks get-credentials --resource-group documenteditorresourcegroup --name documenteditorcluster
```

**Step 4:** Create Kubernetes Services and Deployments

[`Kubernetes Services`](https://kubernetes.io/docs/concepts/services-networking/service/) and [`Deployments`](https://kubernetes.io/docs/concepts/workloads/controllers/deployment/) can be configured in a file. To run the Document Editor server, you must define a Service and a Deployment documenteditorserver. To do this, create the documenteditor-server.yml file in the current directory using the following code.

```
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
```yaml
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: documenteditorserver
name: documenteditorserver
spec:
spec:
replicas: 1
selector:
matchLabels:
app: documenteditorserver
strategy: {}
template:
metadata:
labels:
Expand All @@ -80,36 +79,36 @@ To configure kubectl to connect to your Kubernetes cluster, use the [`az aks get
env:
- name: SYNCFUSION_LICENSE_KEY
value: "YOUR_LICENSE_KEY"

apiVersion: v1
kind: Service
metadata:
---
apiVersion: v1
kind: Service
metadata:
labels:
app: documenteditorserver
name: documenteditorserver
spec:
spec:
ports:
- port: 80
targetPort: 80
selector:
app: documenteditorserver
type: LoadBalancer
```
```

**Step 5:** To create all Services and Deployments needed to run the Document Editor server, execute the following.

```
kubectl create -f ./documenteditor-server.yml
```
```
kubectl apply -f ./documenteditor-server.yml
```

Run the following command to get the Kubernetes cluster deployed service details and copy the external IP address of the Document Editor service.

```
kubectl get all
```
```
kubectl get all
```

Browse the copied external IP address and navigate to the Document Editor Web API control `http://<external-ip>/api/documenteditor`. It returns the default get method response.
Browse to the copied external IP address and navigate to the Document Editor Web API control `http://<external-ip>/api/documenteditor`. It returns the default GET method response.

**Step 6:** Append the Kubernetes service running the URL `http://<external-ip>/api/documenteditor/` to the service URL in the client-side Document Editor control. For more information about the Document Editor control, refer to this [`getting started page`](../getting-started).
**Step 6:** Append the Kubernetes service running URL `http://<external-ip>/api/documenteditor/` to the service URL in the client-side Document Editor control. For more information about the Document Editor control, refer to this [`getting started page`](../getting-started).

For more details about the Azure Kubernetes service, please look deeper into [`Microsoft Azure Kubernetes Service`](https://docs.microsoft.com/en-us/azure/aks/kubernetes-walkthrough) for a production-ready setup.
For more details about the Azure Kubernetes service, refer to the [`Azure Kubernetes Service`](https://docs.microsoft.com/en-us/azure/aks/kubernetes-walkthrough) for a production-ready setup.
Loading