Skip to content

Commit

Permalink
go-ipfs-config: Merge pull request ipfs#80 from ipfs/fix/default-data…
Browse files Browse the repository at this point in the history
…store

fix: correct the default-datastore config profile
  • Loading branch information
Stebalien authored Apr 27, 2020
2 parents 881d761 + 706ff87 commit bcfc522
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions config/profile.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,20 @@ Inverse profile of the test profile.`,
return nil
},
},
"default-datastore": {
Description: `Configures the node to use the default datastore (flatfs).
Read the "flatfs" profile description for more information on this datastore.
This profile may only be applied when first initializing the node.
`,

InitOnly: true,
Transform: func(c *Config) error {
c.Datastore.Spec = flatfsSpec()
return nil
},
},
"flatfs": {
Description: `Configures the node to use the flatfs datastore.
Expand Down Expand Up @@ -189,10 +203,6 @@ fetching may be degraded.
},
}

func init() {
Profiles["default-datatore"] = Profiles["badgerds"]
}

func getAvailablePort() (port int, err error) {
ln, err := net.Listen("tcp", "[::]:0")
if err != nil {
Expand Down

0 comments on commit bcfc522

Please sign in to comment.