Skip to content

Commit

Permalink
osprepare: Include an early bootstrap call for Ceph
Browse files Browse the repository at this point in the history
As all the Ciao components need to have cephfs mounted before fully configuring,
and knowing the full dependency set, we have a core set of dependencies to deal
with first.

These are common to all Ciao components, and are considered the core bootstrap.
Essentially, they add dependencies on the ceph userspace tooling to ensure that
we can first mount, before we ever get to dealing with PrepareOsDeps in the
more generic sense.

Signed-off-by: Ikey Doherty <[email protected]>
  • Loading branch information
Ikey Doherty committed Aug 23, 2016
1 parent 789cffa commit 8ab5f6a
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions osprepare/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,17 @@ type PackageRequirement struct {
// )
type PackageRequirements map[string][]*PackageRequirement

// Required for absolutely core functionality across all Ciao components
var BootstrapRequirements = PackageRequirements{
"ubuntu": {
{"/usr/bin/cephfs", "ceph-fs-common"},
{"/usr/bin/ceph", "ceph-common"},
},
"clearlinux": {
{"/usr/bin/ceph", "storage-cluster"},
},
}

// CollectPackages returns a list of non-installed packages from
// the PackageRequirements received
func collectPackages(dist distro, reqs *PackageRequirements) []string {
Expand Down Expand Up @@ -98,3 +109,9 @@ func PrepareOsDeps(reqs *PackageRequirements) {
}
}
}

// Bootstrap installs all the core dependencies required to bootstrap the core
// configuration of all Ciao components
func Bootstrap() {
PrepareOsDeps(&BootstrapRequirements)
}

0 comments on commit 8ab5f6a

Please sign in to comment.