Commit 34f9f95a authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

Optical component:

- Pre-merge cleanup
parent 849e3a08
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -364,7 +364,7 @@ for COMPONENT in $TFS_COMPONENTS; do
    echo "Waiting for '$COMPONENT' component..."
    COMPONENT_OBJNAME=$(echo "${COMPONENT}" | sed "s/\_/-/")
    kubectl wait --namespace $TFS_K8S_NAMESPACE \
        --for='condition=available' --timeout=90s deployment/${COMPONENT_OBJNAME}service
        --for='condition=available' --timeout=300s deployment/${COMPONENT_OBJNAME}service
    printf "\n"
done

+39 −22
Original line number Diff line number Diff line
# Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

apiVersion: apps/v1
kind: Deployment
metadata:
@@ -9,7 +23,6 @@ spec:
  replicas: 1
  template:
    metadata:
     
      labels:
        app: opticalcontrollerservice
    spec:
@@ -19,13 +32,17 @@ spec:
        image:  localhost:32000/tfs/opticalcontroller:dev
        imagePullPolicy: Never
        ports:
         - containerPort: 5022
        - containerPort: 10060
        - containerPort: 9192
        
        env:
        - name: LOG_LEVEL
          value: "INFO"

        readinessProbe:
          exec:
            command: ["/bin/grpc_health_probe", "-addr=:10060"]
        livenessProbe:
          exec:
            command: ["/bin/grpc_health_probe", "-addr=:10060"]
        resources:
          requests:
            cpu: 500m
@@ -47,8 +64,8 @@ spec:
  ports:
  - name: grpc
    protocol: TCP
    port: 5022
    targetPort: 5022
    port: 10060
    targetPort: 10060
  - name: metrics
    protocol: TCP
    port: 9192

ofc24/startExtraNetConfigAgent.sh

deleted100755 → 0
+0 −25
Original line number Diff line number Diff line
#!/bin/bash

Docker_Container=$1
Docker_Port=$2
if [ -n "$Docker_Container" ] && [ -n "$Docker_Port" ];then
      sudo docker stop "$Docker_Container" -t 1

      sudo docker rm "$Docker_Container"


      echo "Creating TPs"
      screen -dmS t1 -T xterm sh -c "docker run -p 10.0.2.15:"$Docker_Port":2022 -v ~/tfs-ctrl/tempOC/files:/files --name $Docker_Container -it asgamb1/oc23bgp.img:latest"
      sleep  2 
      if [ "$( docker container  inspect -f '{{.State.Running}}' "$Docker_Container")" = "true" ]; then 
            
            docker exec  "$Docker_Container"  cp /files/demoECOC21_4.xml demoECOC21.xml
      
            docker exec "$Docker_Container" /confd/examples.confd/OC23/startNetconfAgent.sh 
      else 
            echo "your container is not running yet"
      fi
else 
   echo "Please define the docker container name and port"
fi         
+2 −1
Original line number Diff line number Diff line
@@ -88,6 +88,7 @@ DEFAULT_SERVICE_GRPC_PORTS = {
    ServiceNameEnum.TE                     .value : 10030,
    ServiceNameEnum.FORECASTER             .value : 10040,
    ServiceNameEnum.E2EORCHESTRATOR        .value : 10050,
    ServiceNameEnum.OPTICALCONTROLLER      .value : 10060,
    ServiceNameEnum.BGPLS                  .value : 20030,

    # Used for test and debugging only
+1 −2
Original line number Diff line number Diff line
@@ -242,5 +242,4 @@ if __name__ == '__main__':
    #print ("topologies{} and devices {}".format(topologies,links))
    rsa = RSA(nodes_dict, links_dict)


    app.run(host='0.0.0.0', port=5022,debug=True)
    app.run(host='0.0.0.0', port=10060,debug=True)
Loading