Skip to content

Commit d3832fb

Browse files
a-thiemeclaude
andcommitted
Add post-merge deployment plan documentation
Explain what changes are needed in named-data/testbed and NLSR gerrit patch 7818 for "just works" deployment after merge. Option B: No backward compatibility - single template change required. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 952a238 commit d3832fb

1 file changed

Lines changed: 83 additions & 3 deletions

File tree

NLSR_PATCH_7818_INTEGRATION.md

Lines changed: 83 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -166,8 +166,88 @@ docker exec testbed-nlsr-1 nlsrc lsdb | grep -A5 osaka
166166

167167
---
168168

169+
---
170+
171+
## After Patch Merge: "Just Works" Deployment (Option B)
172+
173+
This section describes the **minimal changes** needed in named-data/testbed once patch 7818 is merged into NLSR, assuming **no backward compatibility** (Option B).
174+
175+
### Assumption
176+
177+
Patch 7818 is merged into NLSR master branch. A future NLSR release/tag includes the patch. The testbed simply needs to use that version.
178+
179+
### Required Changes
180+
181+
#### 1. named-data/testbed
182+
183+
**Single required change:**
184+
185+
Update `templates/nlsr/nlsr.conf.j2` - advertising section format:
186+
187+
```jinja
188+
advertising
189+
{
190+
{% for prefix in advertised_prefixes %}
191+
{{ prefix }} 1
192+
{% endfor %}
193+
}
194+
```
195+
196+
That's it. **One line change.**
197+
198+
Everything else works automatically because:
199+
- Named Data's CI builds NLSR Docker images with the merged patch
200+
- Testbed's docker-compose.yml already references `ghcr.io/named-data/nlsr:latest` (or a tagged version)
201+
- The NLSR Docker image includes `ENV HOME=/config` (already in official Dockerfile)
202+
203+
#### 2. NLSR Gerrit Patch (7818)
204+
205+
**No changes needed.** The patch works as-is. The breaking config format change is intentional and documented.
206+
207+
### How It Works After Merge
208+
209+
```
210+
named-data/testbed:
211+
├── docker-compose.yml ──► References NLSR image (auto-includes patch)
212+
├── templates/nlsr/nlsr.conf.j2 ──► Generates <prefix> <cost> format ✓
213+
└── Dockerfile ──► Uses official NLSR image (already has HOME=/config)
214+
```
215+
216+
### Rolling Update Process
217+
218+
When patch 7818 is merged and deployed:
219+
220+
```bash
221+
# 1. Pull latest NLSR image (includes merged patch)
222+
docker-compose pull nlsr
223+
224+
# 2. Regenerate config from updated template
225+
ansible-playbook -i inventory site.yml --tags nlsr
226+
227+
# 3. Restart NLSR on each node
228+
docker-compose up -d nlsr
229+
```
230+
231+
### What NOT to Change
232+
233+
The following files do **not** need modification:
234+
235+
- `nlsr.Dockerfile` - Only needed for custom builds before patch is merged
236+
- `docker-compose.override.yml` - Per-deployer override, not in upstream
237+
238+
### Summary
239+
240+
| Repository | Change Required | When |
241+
|------------|----------------|------|
242+
| named-data/testbed | Update `templates/nlsr/nlsr.conf.j2` | One-time after patch merge |
243+
| NLSR (gerrit 7818) | None | Already works |
244+
245+
**Result:** After the single template update, deploying new NLSR versions "just works."
246+
247+
---
248+
169249
## Related Files
170250

171-
- `nlsr.Dockerfile` - Multi-stage build for patched NLSR
172-
- `docker-compose.override.yml` - Override to use patched image
173-
- `templates/nlsr/nlsr.conf.j2` - NLSR configuration template
251+
- `nlsr.Dockerfile` - Multi-stage build for patched NLSR (custom, not needed after merge)
252+
- `docker-compose.override.yml` - Override to use patched image (per-deployer, not upstream)
253+
- `templates/nlsr/nlsr.conf.j2` - NLSR configuration template (the only file needing update)

0 commit comments

Comments
 (0)