Skip to content

Commit

Permalink
Add handover script
Browse files Browse the repository at this point in the history
  • Loading branch information
louisroyer committed Jan 9, 2025
1 parent 1c940e3 commit 8ff7584
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 2 deletions.
9 changes: 7 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,8 @@ set/ran/%: $(BCONFIG)
@echo Set ran to $(@F)
@./scripts/config_edit.py $(BCONFIG) --ran=$(@F)

.PHONY: set/handover
set/handover: $(BCONFIG)
.PHONY: set/handover-ueransim
set/handover-ueransim: $(BCONFIG)
@echo Set handover to true
@./scripts/config_edit.py $(BCONFIG) --handover=true
@$(MAKE) set/dataplane/free5gc
Expand All @@ -116,6 +116,11 @@ set/handover: $(BCONFIG)
@$(MAKE) set/full-debug/true
@$(MAKE) set/ran/dev

.PHONY: set/handover-nextmn
set/handover-nextmn: $(BCONFIG)
@echo Set handover to true
@./scripts/config_edit.py $(BCONFIG) --handover=true

.PHONY: clean
clean:
@rm -rf $(BUILD_DIR)
Expand Down
14 changes: 14 additions & 0 deletions scripts/handover-uel3.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/usr/bin/env bash
# Copyright 2025 Louis Royer. All rights reserved.
# Use of this source code is governed by a MIT-style license that can be
# found in the LICENSE file.
# SPDX-License-Identifier: MIT
#
curl -X POST --json '
{
"ue-ctrl": "http://[fd00:0:0:0:2:8000:0:c]:8080",
"gnb-target": "http://[fd00:0:0:0:2:8000:0:8]:8080",
"sessions": [{
"ue-addr": "10.2.1.1",
"dnn": "free5gc"
}]}' "http://[fd00::2:8000:0:7]:8080/cli/ps/handover"
21 changes: 21 additions & 0 deletions templates/compose.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -1416,6 +1416,10 @@ services:
depends_on:
gnbl1:
condition: service_started
#~ if config["topology"]["ran"]["handover"]
gnbl2:
condition: service_started
#~ endif
environment:
GIN_MODE: "release"
HTTP_ADDRESS: "{{ ipv6('uel1', 'control') }}"
Expand All @@ -1424,6 +1428,9 @@ services:
bind-addr: "[{{ ipv6('uel1', 'ran') }}]:1234"
gnbs:
- "http://[{{ ipv6('gnbl1', 'control') }}]:8080"
#~ if config["topology"]["ran"]["handover"]
- "http://[{{ ipv6('gnbl2', 'control') }}]:8080"
#~ endif
pdu-sessions:
- gnb: "http://[{{ ipv6('gnbl1', 'control') }}]:8080"
dnn: "srv6"
Expand Down Expand Up @@ -1467,6 +1474,10 @@ services:
depends_on:
gnbl1:
condition: service_started
#~ if config["topology"]["ran"]["handover"]
gnbl2:
condition: service_started
#~ endif
environment:
GIN_MODE: "release"
HTTP_ADDRESS: "{{ ipv6('uel3', 'control') }}"
Expand All @@ -1475,6 +1486,9 @@ services:
bind-addr: "[{{ ipv6('uel3', 'ran') }}]:1234"
gnbs:
- "http://[{{ ipv6('gnbl1', 'control') }}]:8080"
#~ if config["topology"]["ran"]["handover"]
- "http://[{{ ipv6('gnbl2', 'control') }}]:8080"
#~ endif
pdu-sessions:
- gnb: "http://[{{ ipv6('gnbl1', 'control') }}]:8080"
dnn: "free5gc"
Expand Down Expand Up @@ -1518,6 +1532,10 @@ services:
depends_on:
gnbl1:
condition: service_started
#~ if config["topology"]["ran"]["handover"]
gnbl2:
condition: service_started
#~ endif
environment:
GIN_MODE: "release"
HTTP_ADDRESS: "{{ ipv6('uel5', 'control') }}"
Expand All @@ -1526,6 +1544,9 @@ services:
bind-addr: "[{{ ipv6('uel5', 'ran') }}]:1234"
gnbs:
- "http://[{{ ipv6('gnbl1', 'control') }}]:8080"
#~ if config["topology"]["ran"]["handover"]
- "http://[{{ ipv6('gnbl2', 'control') }}]:8080"
#~ endif
pdu-sessions:
- gnb: "http://[{{ ipv6('gnbl1', 'control') }}]:8080"
dnn: "nextmn-upf"
Expand Down

0 comments on commit 8ff7584

Please sign in to comment.