Closed mattwelke closed 3 years ago
Hey @welkie,
Thanks for the report. I believe this issue is caused by running the above commands (and most importantly, making the /code
and /data
directories) as root.
All Pelias containers run as a non-root user. What happens if you re-run the script as a non-root user? You might have to pick different directories than /code
and /data
.
@orangejulius Thanks for the tip. Will try as non root user and report back.
I tried it as a sudo non-root user but I had the same problem. I'm going to spend some more time reading the documentation before raising further issues though because I have to admit I just grabbed that script and ran it, not understanding what the Pelias setup does in detail yet.
@welkie Hello welkie. How did you solve this problem? I have the same questions too.
@sophia-xll Ended up feeling overwhelmed trying to set this up and gave up for now unfortunately. Sorry. :(
solved this error, set the permission of dir manually as docker user.
sudo chown -R pelias:pelias /data/openaddresses
Hi folks, Just doing some issue pruning, I think we've taken care of this one.
If anyone else winds up here with permission issues here are some general hints:
pelias ...
commands as root
or using sudo
$DATA_DIR
is owned by the same user you are running the pelias ...
commands as (and also not owned by root)rm -rf
to (carefully) remove the $DATA_DIR
and re-create it as the same (non-root) user you are running the pelias ...
commands as
I tried using the example build script in the Git repo readme:
I put this into a script called
build.sh
in the root home directory and usedchmod +x build.sh
to make it executable.But even though I was logged into root and created the directory
/data
, it was only able to create a few of the data/* directories (one of them waselasticsearch
) before the script ran into errors indiciating no permission to create the others. This caused the script to fail right before it started downloading the address data:At this point, it's running, but appears to error out when a request comes in: