Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(pallet-tfgrid): allow hdd only nodes to register on chain #971

Merged
merged 7 commits into from
May 28, 2024

Conversation

renauter
Copy link
Collaborator

Description

We want to allow registration of HDD only nodes on chain for Holochain usage.

Implemented solution:

  1. Similar to what already exists for SSD, add a minimum HDD size requirement on resources.validate_hru()
  2. Then, on validating, make sure node has at least 1 minimum storage capacity available
ensure!(resources.validate_hru() || ensure!(resources.validate_sru() , Error::<T>::InvalidStorageInput); 

A "reasonable" minimum HDD size requirement is set to 100 GB (same as SSD).

Related Issues:

Checklist:

Please delete options that are not relevant.

@renauter renauter marked this pull request as ready for review May 28, 2024 15:18
Copy link
Member

@sameh-farouk sameh-farouk left a comment

Choose a reason for hiding this comment

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

LGTM
Thank you

@renauter renauter merged commit 3e7c912 into development May 28, 2024
2 checks passed
@renauter renauter deleted the feat_allow_hdd_only_nodes_to_register branch May 28, 2024 18:11
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.

2 participants