Skip to content

Commit

Permalink
Merge pull request #554 from threefoldtech/development_not_update_myc…
Browse files Browse the repository at this point in the history
…elium_keys_from_state

don't update mycelium keys from the state
  • Loading branch information
rawdaGastan authored Nov 26, 2024
2 parents 28987ee + 32b9fab commit b84b158
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 17 deletions.
1 change: 0 additions & 1 deletion provider/cmd/pulumi-resource-threefold/schema.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{
"name": "threefold",
"displayName": "Threefold Grid",
"version": "0.7.7",
"description": "The Pulumi Resource Provider for the Threefold Grid.",
"keywords": [
"pulumi",
Expand Down
16 changes: 0 additions & 16 deletions provider/network_parser.go
Original file line number Diff line number Diff line change
Expand Up @@ -165,28 +165,12 @@ func updateNetworkFromState(network workloads.Network, state NetworkState) error
nodeDeploymentID[uint32(node)] = uint64(deploymentID)
}

myceliumKeys := make(map[uint32][]byte)
for nodeID, myceliumKey := range state.MyceliumKeys {
nodeID, err := strconv.Atoi(fmt.Sprint(nodeID))
if err != nil {
return err
}

myceliumKey, err := hex.DecodeString(myceliumKey)
if err != nil {
return err
}

myceliumKeys[uint32(nodeID)] = myceliumKey
}

network.SetAccessWGConfig(state.AccessWGConfig)
network.SetExternalIP(&externalIP)
network.SetExternalSK(externalSk)
network.SetPublicNodeID(uint32(state.PublicNodeID))
network.SetNodesIPRange(nodesIPRange)
network.SetNodeDeploymentID(nodeDeploymentID)
network.SetMyceliumKeys(myceliumKeys)

return nil
}
Expand Down

0 comments on commit b84b158

Please sign in to comment.