Skip to content

Conversation

knolleary
Copy link
Member

@knolleary knolleary commented Oct 7, 2025

Closes #6074

Description

Splits the cert-nodes feature flag into two - cert nodes and ff-exclusive nodes.

Updates the UI to simplify the configuration. Admins should only need to provide the registry token

image

I have renamed the settings we are using as certNodes is now a subset of the full thing. Only impact will be our staging env that'll need the token readding. The settings can be provided via the yaml file under:

  • platform:ff-npm-registry:url
  • platform:ff-npm-registry:token
  • platform:ff-npm-registry:catalogue:certifiedNodes
  • platform:ff-npm-registry:catalogue:ffNodes

All except for token have the right defaults applied (albeit inline in the code rather than the defaults file... ).

@knolleary
Copy link
Member Author

Fixes pushed for the tests.

Turns out devices expect palette.catalogues and projects expect palette.catalogue.

Updated tests to check the settings are properly updated depending on the feature flags - more so on the device side.

Copy link

codecov bot commented Oct 7, 2025

Codecov Report

❌ Patch coverage is 94.54545% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 76.85%. Comparing base (a03f01a) to head (8d6dbbc).
⚠️ Report is 24 commits behind head on main.

Files with missing lines Patch % Lines
forge/routes/api/deviceLive.js 96.15% 1 Missing ⚠️
forge/routes/api/project.js 96.15% 1 Missing ⚠️
forge/routes/api/settings.js 50.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6105      +/-   ##
==========================================
+ Coverage   76.81%   76.85%   +0.04%     
==========================================
  Files         380      381       +1     
  Lines       19230    19272      +42     
  Branches     4624     4641      +17     
==========================================
+ Hits        14771    14812      +41     
- Misses       4459     4460       +1     
Flag Coverage Δ
backend 76.85% <94.54%> (+0.04%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@hardillb
Copy link
Contributor

hardillb commented Oct 8, 2025

@knolleary just checking

- platform:ff-npm-registry:url
- platform:ff-npm-registry:token
- platform:ff-npm-registry:catalogue:certifiedNodes
- platform:ff-npm-registry:catalogue:ffNodes

maps to this in the flowforge.yml file

platform:
  ff-npm-registry:
    url: https://registry.flowfuse.com
    token: fdfafdsafsad
    catalogue:
      certifiedNodes: https://ff-certified.nodes.flowfuse.cloud/catalogue.json
      ffNodes: https://ff-certified-nodes.flowfuse.cloud/ff/catalogue.json

@hardillb
Copy link
Contributor

hardillb commented Oct 8, 2025

Actually I don't see anything that would load these default settings from the flowforge.yml file or am I missing something?

@knolleary
Copy link
Member Author

@hardillb I completely overlooked config/settings being separate entities.

  1. have removed all but the token property from settings - as that's the only one to dynamically change
  2. the registry url and catalog urls can now be overridden via the config file as:
ff-npm-registry:
   url: http://example.com
   catalogue:
      certifiedNodes: http:/example.com
      ffNodes: http:/example.com

Note that token cannot be set via config file - must be done via settings in the admin panel. This avoids having two sources of truth for the value.

Copy link
Contributor

@hardillb hardillb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a copy/paste in the error message device vs project

Co-authored-by: Ben Hardill <ben@flowforge.com>
@knolleary knolleary merged commit f3680d8 into main Oct 8, 2025
23 checks passed
@knolleary knolleary deleted the 6074-ff-exc-nodes-flag branch October 8, 2025 14:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add FlowFuse Exclusive node feature flag

2 participants