From 9236fd2a5340a7cc4ef591fc369f0a7e5f132c89 Mon Sep 17 00:00:00 2001 From: chris meyers Date: Fri, 26 Jul 2019 13:15:53 -0400 Subject: [PATCH] fake it till you make it! * The user awx is passed to the launch of our dev docker container. The docker system automagically creates that user for us and sets the home dir to /tmp in /etc/passwd. Many methods of detecting the user home dir don't use that. Instead, they use the HOME env var. This is a half-way solution that solves the problem of python expanding the ~ dir. * If other things break because they determine the users home dir via /etc/passwd entry then a more in-depth fix will be needed. --- tools/docker-compose/Dockerfile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tools/docker-compose/Dockerfile b/tools/docker-compose/Dockerfile index 413be8b7daa4..ea3e9c7951bf 100644 --- a/tools/docker-compose/Dockerfile +++ b/tools/docker-compose/Dockerfile @@ -158,4 +158,6 @@ RUN for file in /etc/passwd /etc/supervisord.conf \ /venv/awx/lib/python3.6/site-packages/awx.egg-link /var/run/nginx.pid; \ do touch $file; chmod -R g+rwx $file; chgrp -R root $file; done +ENV HOME /var/lib/awx + ENV PATH=/usr/local/n/versions/node/10.15.0/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin