SDEWAN: Setup by pull mode

Version requirement:

​ Ubuntu: 20.04

​ scc: build from https://github.com/intel-sandbox/akraino-sdewan/tree/rc-22.06

​ cnf: docker pull integratedcloudnative/sdewan-cnf:0.5.3

crd-controller: docker pull integratedcloudnative/sdewan-controller:0.5.3

0.Create an Github repo for pull mode

​ Create an Github repo for SDEWAN pull mode, for example: https://github.com/airren/flux

​ Next, prepare an Personal access tokens for SDEAN to access the repo.

  • Update your repo info and token to this file SDEWAN-SetUp/ewo-tools/cluster-sync-object.yaml.

     1# SDEWAN-SetUp/ewo-tools/cluster-sync-object.yaml
     2---
     3# creating cluster-sync-obj
     4version: ewo/v1
     5resourceContext:
     6anchor: overlays/overlay1/cluster-sync-objects
     7metadata:
     8name: cso2
     9description:
    10userData1:
    11userData2:
    12spec:
    13kv:
    14- gitType: github
    15- userName: Airren  # change to your own github username
    16- gitToken: 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   # change to your own
    17- repoName: flux                 # change to your own
    18- branch: main
    
  • Update the GITHUB_TOKEN in SDEWAN-SetUp/setup_flux.sh

  • Update the repo info and token in SDEWAN-SetUp/monitor_stuff/monitor_configs

    1username=Airren  # change to your own
    2token=ghp_LaAMXYmdcSWbmSOp9fQPL # change to your own
    3repo_name=flux
    4cluster=akraino_scc_overlay1+edge-1
    5http_proxy=http://proxy-prc.intel.com:913
    6https_proxy=http://proxy-prc.intel.com:913
    

1. Setup 4 VMs with SDEWAN base components

1./0_auto_setup.sh -n <vm-perfix>

After that, you will install most the components of SDEWAN. But due to the proxy limitation, we have to do some check work manually.

a. Add proxy configuration to the git repo for Hub/Edge-1/Edge-2. https://github.com/Airren/flux/blob/main/clusters/akraino_scc_overlay1%2Bedge-2/flux-system/kustomization.yaml

 1patches:
 2  - patch: |
 3      apiVersion: apps/v1
 4      kind: Deployment
 5      metadata:
 6        name: all
 7      spec:
 8        template:
 9          spec:
10            containers:
11              - name: manager
12                env:
13                  - name: "HTTPS_PROXY"
14                    value: "http://proxy-prc.intel.com:913"
15                  - name: "HTTP_PROXY"
16                    value: "http://proxy-prc.intel.com:913"
17                  - name: "NO_PROXY"
18                    value: "10.0.11.1/24,10.95.62.1/16,192.169.0.1/24,192.168.0.1/24,10.233.0.1/16,localhost,10.96.0.1/24,192.168.174.0/24,172.17.0.1/24,.cluster.local.,.cluster.local,.svc"      
19    target:
20      kind: Deployment
21      labelSelector: app.kubernetes.io/part-of=flux

b. Re run flux init on Hub/Edge-1/Edge-2, check the result

1# for hub cluster
2setup_flux.sh hub
3# for edge-1 cluster
4setup_flux.sh edge-1
5# for edge-2 cluster
6setup_flux.sh edge-2

image-20220704101648464

c. Re-deploy monitor if need on Hub/Edge-1/Edge-2 respectively.

1SDEWAN-SetUp/monitor_stuff/monitor-deploy.sh

2.Register Overlay

1cd SDEWAN-SetUp/ewo-tools 
2./ewoctl --config ./ewo-config.yaml apply -f pre.yaml
3./ewoctl --config ./ewo-config.yaml apply -f cluster-sync-object.yaml

3.Register Hub/Edge-1/Edge-2

1cd SDEWAN-SetUp/ewo-tools 
2./ewoctl --config ./ewo-config.yaml apply -f huba.yaml
3./ewoctl --config ./ewo-config.yaml apply -f edge-1.yaml
4./ewoctl --config ./ewo-config.yaml apply -f edge-2.yaml

4.Register Hub/Edge-1/Edge-2

1cd SDEWAN-SetUp/ewo-tools 
2./ewoctl --config ./ewo-config.yaml apply -f huba-edge-1-con.yaml
3./ewoctl --config ./ewo-config.yaml apply -f huba-edge-2-con.yaml

5.Deploy Application as before.

Other Notes: (Not Need, Just for Debug)

1 kubectl patch deployments.apps -n flux-system source-controller --patch-file patch.yaml
2 
3 k patch deployments.apps -n sdewan-system rsync --patch-file rsync-patch.yaml