X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/67e5e79be0d7d668ffa5bae4706989914f5c4292..a357f5f197dbe54314608d4c5acbdd9e1959afba:/lib/install/deps.go diff --git a/lib/install/deps.go b/lib/install/deps.go index 8df3fba532..714604c845 100644 --- a/lib/install/deps.go +++ b/lib/install/deps.go @@ -29,6 +29,7 @@ import ( var Command cmd.Handler = &installCommand{} const devtestDatabasePassword = "insecure_arvados_test" +const goversion = "1.17.1" type installCommand struct { ClusterType string @@ -178,9 +179,15 @@ func (inst *installCommand) RunCommand(prog string, args []string, stdin io.Read "r-cran-roxygen2", "r-cran-xml", "sudo", + "uuid-dev", "wget", "xvfb", ) + if dev || test { + pkgs = append(pkgs, + "squashfs-tools", // for singularity + ) + } switch { case osv.Debian && osv.Major >= 10: pkgs = append(pkgs, "libcurl4") @@ -239,12 +246,12 @@ make install } if !prod { - goversion := "1.16.3" if havegoversion, err := exec.Command("/usr/local/bin/go", "version").CombinedOutput(); err == nil && bytes.HasPrefix(havegoversion, []byte("go version go"+goversion+" ")) { logger.Print("go " + goversion + " already installed") } else { err = inst.runBash(` cd /tmp +rm -rf /var/lib/arvados/go/ wget --progress=dot:giga -O- https://storage.googleapis.com/golang/go`+goversion+`.linux-amd64.tar.gz | tar -C /var/lib/arvados -xzf - ln -sf /var/lib/arvados/go/bin/* /usr/local/bin/ `, stdout, stderr) @@ -283,7 +290,7 @@ ln -sf /var/lib/arvados/bin/geckodriver /usr/local/bin/ } } - nodejsversion := "v10.23.1" + nodejsversion := "v12.22.2" if havenodejsversion, err := exec.Command("/usr/local/bin/node", "--version").CombinedOutput(); err == nil && string(havenodejsversion) == nodejsversion+"\n" { logger.Print("nodejs " + nodejsversion + " already installed") } else { @@ -315,6 +322,27 @@ rm ${zip} } } + singularityversion := "3.7.4" + if havesingularityversion, err := exec.Command("/var/lib/arvados/bin/singularity", "--version").CombinedOutput(); err == nil && strings.Contains(string(havesingularityversion), singularityversion) { + logger.Print("singularity " + singularityversion + " already installed") + } else if dev || test { + err = inst.runBash(` +S=`+singularityversion+` +tmp=/var/lib/arvados/tmp/singularity +trap "rm -r ${tmp}" ERR EXIT +cd /var/lib/arvados/tmp +git clone https://github.com/sylabs/singularity +cd singularity +git checkout v${S} +./mconfig --prefix=/var/lib/arvados +make -C ./builddir +make -C ./builddir install +`, stdout, stderr) + if err != nil { + return 1 + } + } + // The entry in /etc/locale.gen is "en_US.UTF-8"; once // it's installed, locale -a reports it as // "en_US.utf8". @@ -462,7 +490,7 @@ rm ${zip} {"mkdir", "-p", "log", "tmp", ".bundle", "/var/www/.gem", "/var/www/.bundle", "/var/www/.passenger"}, {"touch", "log/production.log"}, {"chown", "-R", "--from=root", "www-data:www-data", "/var/www/.gem", "/var/www/.bundle", "/var/www/.passenger", "log", "tmp", ".bundle", "Gemfile.lock", "config.ru", "config/environment.rb"}, - {"sudo", "-u", "www-data", "/var/lib/arvados/bin/gem", "install", "--user", "--conservative", "--no-document", "bundler:1.16.6", "bundler:1.17.3", "bundler:2.0.2"}, + {"sudo", "-u", "www-data", "/var/lib/arvados/bin/gem", "install", "--user", "--conservative", "--no-document", "bundler:2.2.19"}, {"sudo", "-u", "www-data", "/var/lib/arvados/bin/bundle", "install", "--deployment", "--jobs", "8", "--path", "/var/www/.gem"}, {"sudo", "-u", "www-data", "/var/lib/arvados/bin/bundle", "exec", "passenger-config", "build-native-support"}, {"sudo", "-u", "www-data", "/var/lib/arvados/bin/bundle", "exec", "passenger-config", "install-standalone-runtime"},