GregYankovoy / docker-goaccess

goaccess reverse proxied through nginx for ease of use
MIT License
32 stars 14 forks source link

Some questions about your Dockerfile #7

Closed hot22shot closed 3 years ago

hot22shot commented 3 years ago

Hi,

First of all thank you for sharing your container, it saved me quite a lot of time ! I'm trying to make my own version of it updated to v1.4.3 and I had some questions about how you build your image :

  1. What is the purpose of the argument geolite_version ?

I obtained a permalink from maxmind to download the GeoLite2 City database and putting this URL in the argument geolite_city_link worked for me but I'm wondering if I'm missing something.

  1. When creating the final image I encountered the following error :
Step 10/13 : RUN chmod +x /usr/local/bin/goaccess.sh &&     chmod -R 777 /var/tmp/nginx
 ---> Running in dd18c52bdd78
chmod: /var/tmp/nginx: No such file or directory

Commenting the chmod somehow got me a working image but, again, what do I miss here ?

Cheers

GregYankovoy commented 3 years ago

Hi!

  1. I believe I intended to use this to be able to substitute geolite versions on build time. However, due to the new download mechanisms I was not able to do this. It can safely be removed.
  2. Are you installing nginx in alpine? If you are using a different base container, the nginx tmp stuff may reside in a different location (I believe nginx wouldn't start up unless I modified the permissions of this folder. The official nginx container probably uses better practices). Keep in mind that nginx is used within this container to front goaccess through a single endpoint. This step may be unnecessary depending on how you are configuring your container/user/permissions/nginx/etc

Let me know if you have any other questions and I'll do my best to answer them.

hot22shot commented 3 years ago

Thanks for your reply,

  1. Ok though so.
  2. Yes nginx is installed and seems to work as intended, I based my image on the latest Alpine, I suppose the little discrepancies come from that.

I added a basic authentification, forced the locale to my langage and persistence of data.