Picture of Laura Epton
Help required: authoring tool Mac installation
by Laura Epton - Thursday, 6 September 2018, 9:23 AM
 

Hi 

I'm looking for some advice or guidance to help me install the Adapt Authoring Tool on a Mac. 

  • MacOS High Sierra.
  • Version 10.13.3

I’ve followed the instructions to install the prerequisites and seem to come unstuck at ‘Install the Adapt Command Line Tools’. 

I’m following the instructions outlined here: https://github.com/adaptlearning/adapt_authoring/wiki/Installing-Adapt-Origin#1

I have the following installed. 

  • git version 2.16.2
  • node -v v8.10.0
  • npm -v 5.6.0
  • ffmpeg version 3.4.2 
  • grunt-cli@1.2.0
  •  MongoDB
  • and successfully cloned the Adapt_Authoring Project

I seem to be able to install -g grunt-cli. When I try to install -g adapt-cli, I come to this error message. I wondered if anyone could help me understand what is going wrong and gives some suggestions about how I can solve the problem. 

I am new to this so not hugely technical. Thanks in advance.

Laura

Error message: 

sudo npm install -g adapt-cli

/usr/local/bin/adapt -> /usr/local/lib/node_modules/adapt-cli/bin/adapt

 

> nodegit@0.20.3 install /usr/local/lib/node_modules/adapt-cli/node_modules/nodegit

> node lifecycleScripts/preinstall && node lifecycleScripts/install

 

[nodegit] Running pre-install script

[nodegit] Configuring libssh2.

{ Error: Command failed: /usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/libssh2/configure --with-libssl-prefix=/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/openssl/openssl

/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/libssh2/configure: line 2059: config.log: Permission denied

/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/libssh2/configure: line 2069: config.log: Permission denied

 

    at ChildProcess.exithandler (child_process.js:275:12)

    at emitTwo (events.js:126:13)

    at ChildProcess.emit (events.js:214:7)

    at maybeClose (internal/child_process.js:925:16)

    at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)

  killed: false,

  code: 1,

  signal: null,

  cmd: '/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/libssh2/configure --with-libssl-prefix=/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/openssl/openssl' }

/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/libssh2/configure: line 2059: config.log: Permission denied

/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/libssh2/configure: line 2069: config.log: Permission denied

 

[nodegit] ERROR - Could not finish preinstall

{ Error: Command failed: /usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/libssh2/configure --with-libssl-prefix=/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/openssl/openssl

/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/libssh2/configure: line 2059: config.log: Permission denied

/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/libssh2/configure: line 2069: config.log: Permission denied

 

    at ChildProcess.exithandler (child_process.js:275:12)

    at emitTwo (events.js:126:13)

    at ChildProcess.emit (events.js:214:7)

    at maybeClose (internal/child_process.js:925:16)

    at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)

  killed: false,

  code: 1,

  signal: null,

  cmd: '/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/libssh2/configure --with-libssl-prefix=/usr/local/lib/node_modules/adapt-cli/node_modules/nodegit/vendor/openssl/openssl' }

npmERR!code ELIFECYCLE

npmERR!errno 1

npmERR! nodegit@0.20.3 install: `node lifecycleScripts/preinstall && node lifecycleScripts/install`

npmERR! Exit status 1

npmERR! 

npmERR! Failed at the nodegit@0.20.3 install script.

npmERR! This is probably not a problem with npm. There is likely additional logging output above.

 

npmERR! A complete log of this run can be found in:

npmERR!     /Users/lauraepton/.npm/_logs/2018-04-16T19_41_01_659Z-debug.log

Picture of John Niezen
Re: In
by John Niezen - Tuesday, 17 April 2018, 6:07 AM
 

Hi Laura,

2 things;

1 your Node is on too high version, use v6, v8 is not yet supported, so use v6.

2 your lifecycle problem has to do with some node legacy stuff, search this forum, and you will find some tips how to solve it.

John

Picture of Thomas Wiley
Re: In
by Thomas Wiley - Thursday, 6 September 2018, 2:02 AM
 

I had the same issue. It fails when trying to install nodegit AFAIK. Searched all over and couldn't find a resolution. I tried to do npm -g install nodegit as root and got the same permission error. How I got it to work was to install adapt-cli in some temp folder that I knew there wouldn't be a permission issue. So I navigated to /users/my_name/tmp in the terminal and ran npm install adapt-cli from there and it ran fine.

After it finished I copied the many newly created folders in /users/my_name/tmp/node_modules and moved them to /usr/local/lib/node_modules. I had to provide my admin password to allow the files to be written. After that the adapt command worked globally as expected.

Picture of Daniel Seixas
Re: In
by Daniel Seixas - Friday, 14 September 2018, 10:22 AM
 

Just a quick note if helps anybody about Thomas Wiley' answer.

It worked just fine but I had to grant permissions in the temp folder

chmod ugo+w .

And it is important to NOT to "sudo" the command