Islandora-Labs / islandora_solution_pack_oralhistories

Adds all required Fedora objects to allow users to ingest and retrieve Oral Histories (video/audio) files through the Islandora interface
GNU General Public License v3.0
13 stars 23 forks source link

401 Unauthorized when Enabling in ISLE #127

Closed McFateM closed 6 years ago

McFateM commented 6 years ago

I've scripted some module installation inside my local ISLE (https://github.com/Islandora-Collaboration-Group/ISLE) environment but, after installing this solution pack in the prescribed manner I'm getting an error like this when I try to enable it.

Other solution packs and modules have been enabled prior to this, under the same user account, so I'm puzzled what the cause of this might be. It's probably more an ISLE issue than an OH one, but I would appreciate if anyone can suggest a solution, or even a means of better diagnosing what's happening.

The following extensions will be enabled: islandora_oralhistories, transcripts_ui
Do you really want to continue? (y/n): y
WD islandora: Failed to ingest object: islandora:oralhistoriesCModelcode: 401message: Unauthorized                                                                                                                            [error]
exception 'HttpConnectionException' with message 'Unauthorized' in /var/www/html/sites/all/libraries/tuque/HttpConnection.php:486                                                                                             [error]
MarcusBarnes commented 6 years ago

@McFateM Thank you for reporting. I'v never seen this before. I'm not sure if it's something related to how Islandora is deployed in ISLE. We can review the Tuque related code in Oral Histories to see if there's something there that may give us a clue on how to proceed.

McFateM commented 6 years ago

A little follow-up on this...

I still can't find the root of this issue so for now I'm working around it with the following changes in our Apache container's install script:

if [ -v ISLANDORA_SOLUTION_PACK_ORALHISTORIES ]; then
  echo -e "${RED}Attention! The Islandora Oral Histories Solution Pack requires some follow-up..."
  echo -e "${BLUE}Visit https://isle.localdomain/admin/modules to enable the module then https://isle.localdomain/admin/islandora/solution_pack_config/solution_packs to install reqiured objects."
  echo -e "${BLUE}Follow additional instructions posted at https://github.com/Islandora-Labs/islandora_solution_pack_oralhistories/blob/7.x/README.md to complete the process."
  echo -e "${NC}"
  # cd /var/www/html/sites/default
  # /usr/local/bin/drush en islandora_oralhistories -y    <-- This line, when active, ends with the following error 'WD islandora: Failed to ingest object: islandora:oralhistoriesCModel code: 401 message: Unauthorized.'
  # /usr/local/bin/drush cc all
fi

Note that following the instructions above to 'manually' enable the module and install the CModel works nicely.

MarcusBarnes commented 6 years ago

Thanks for the update. For focusing debugging, it appears that on install, when there is the intial attempt to add islandora:oralhistoriesCModel (Oral Histories Content Model) to Fedora, something goes wrong on the ISLE infrastructure. That at least narrows down which parts of the code could be the culprit or which parts of the ISLE setup may need to be modified. @McFateM Do you know if anyone in the ISLE community yet tried installing non-core Islandora content models?

MarcusBarnes commented 6 years ago

@McFateM Is it possible to run drush using the same user that Fedora runs under? I wonder if this is a permission issue on the ILSE setup and the results of attempting this might give us some insight.

McFateM commented 6 years ago

@MarcusBarnes Thanks for the quick follow-up. I think I'm the only person attempting to push OH, or any non-core CModels, into an ISLE instance. I'll ask others in the group about this and see if we can figure it out. If/when we do I'll be sure to follow-up here.

McFateM commented 6 years ago

@MarcusBarnes Got it. Simple fix. Ben Rosner suggested I add -u 1 to the drush en command (like all the others I run in the script) and that fixed it. Duh. Closing this issue and I'll try to pay better attention to detail next time. Take care.

MarcusBarnes commented 6 years ago

@McFateM Thank you for updating us on this issue and thanks for using the Oral Histories Solution Pack.