briantist/galactory

Permission denied

Closed this issue · 2 comments

Hi,

there's a great change I'm missing something obvious,
but I can't get galactory to work.
My config file at ~/.galactory/galactory.conf looks like this:
listen-addr=127.0.0.1 listen-port=80 server-name=galactory.lan.example.com:80 artifactory-path=https://artifactory.lan.example.com/artifactory/backsys-galactory/ artifactory-api-key=<myArtifactoryAccessToken> proxy-upstream=https://galaxy.ansible.com cache-write=true log-level=DEBUG log-file=galactory.log

galactory does read the conf file, because the log file I specified was created.
However, all I get is a
[galactory@myserver ~]$ python3 -m galactory -c .galactory/galactory.conf Serving Flask app 'galactory' Debug mode: off Permission denied

Any advice on how to solve this?

Many thanks.

Nevermind - using the docker image works fine.

Hi @Uquout7o ! On Linux you must be root to bind to ports 0-1024, so the issue is probably that you were trying to bind to port 80 without being root. You could confirm this is the case without running the software as root by trying it again with a higher port.

few other things:

  • you can specify your Artifactory API key by environment variable if you want to keep it out of the config file
  • you can add the API key to a separate config file in the same directory (which maybe has more strict permissions or something)
  • server-name is probably not needed; by default it should be using whichever name gets sent in the host header. If you have to use this option to get it to work right for, could you let me know how you're using it and why it's needed? It would be really helpful for me so that I can understand and best support the feature.
  • since your config file is in one of the default locations, you don't have to use -c but it's ok to do so

On a separate note, I would love to hear more about how you're using galactory!
What's working well, what isn't, what would you like to see, etc.