Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
controller
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TFS
controller
Commits
ae70dd2a
Commit
ae70dd2a
authored
1 year ago
by
famelis
Browse files
Options
Downloads
Patches
Plain Diff
refactor: change ztp naming for device component
parent
8f367f78
No related branches found
No related tags found
2 merge requests
!235
Release TeraFlowSDN 3.0
,
!166
Refactor/47 ubi rename ztp component
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/device/service/DeviceServiceServicerImpl.py
+4
-4
4 additions, 4 deletions
src/device/service/DeviceServiceServicerImpl.py
src/device/service/drivers/xr/README_XR.md
+3
-3
3 additions, 3 deletions
src/device/service/drivers/xr/README_XR.md
with
7 additions
and
7 deletions
src/device/service/DeviceServiceServicerImpl.py
+
4
−
4
View file @
ae70dd2a
...
...
@@ -123,13 +123,13 @@ class DeviceServiceServicerImpl(DeviceServiceServicer):
t9
=
time
.
time
()
automation
_service_host
=
get_env_var_name
(
ServiceNameEnum
.
AUTOMATION
,
ENVVAR_SUFIX_SERVICE_HOST
)
ztp
_service_host
=
get_env_var_name
(
ServiceNameEnum
.
ZTP
,
ENVVAR_SUFIX_SERVICE_HOST
)
environment_variables
=
set
(
os
.
environ
.
keys
())
if
automation
_service_host
in
environment_variables
:
#
Automation
component is deployed; leave devices disabled.
Automation
will enable them.
if
ztp
_service_host
in
environment_variables
:
#
ZTP
component is deployed; leave devices disabled.
ZTP
will enable them.
device
.
device_operational_status
=
DeviceOperationalStatusEnum
.
DEVICEOPERATIONALSTATUS_DISABLED
else
:
#
Automation
is not deployed; assume the device is ready while onboarding and set them as enabled.
#
ZTP
is not deployed; assume the device is ready while onboarding and set them as enabled.
device
.
device_operational_status
=
DeviceOperationalStatusEnum
.
DEVICEOPERATIONALSTATUS_ENABLED
device_id
=
context_client
.
SetDevice
(
device
)
...
...
This diff is collapsed.
Click to expand it.
src/device/service/drivers/xr/README_XR.md
+
3
−
3
View file @
ae70dd2a
...
...
@@ -52,7 +52,7 @@ Script requires more variables than before as of February 2023.
# See https://labs.etsi.org/rep/tfs/controller/-/blob/develop/my_deploy.sh
# Use docker run -d -p 32000:5000 --restart=always --name registry registry:2
export
TFS_REGISTRY_IMAGE
=
"http://localhost:32000/tfs/"
export
TFS_COMPONENTS
=
"context device
automation
monitoring pathcomp service slice compute webui load_generator"
export
TFS_COMPONENTS
=
"context device
ztp
monitoring pathcomp service slice compute webui load_generator"
export
TFS_IMAGE_TAG
=
"dev"
export
TFS_K8S_NAMESPACE
=
"tfs"
export
TFS_EXTRA_MANIFESTS
=
"manifests/nginx_ingress_http.yaml"
...
...
@@ -113,14 +113,14 @@ Run deploy script to build in docker containers and then instantiate to configur
If protobuf definitions have changed, regenerate version controlled Java files manually
(it is a horrifying bug in build system that this is not automated!).
```
cd
automation
cd
ztp
# In case Java is not already installed
sudo apt-get install openjdk-11-jdk -y
export MAVEN_OPTS='--add-exports=java.base/jdk.internal.module=ALL-UNNAMED --add-exports jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED --add-exports jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED --add-exports jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED --add-exports jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED --add-exports jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED --add-exports jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED'
cd src/policy
./mvnw compile
cd -
cd src/
automation
cd src/
ztp
./mvnw compile
```
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment