Merge pull request #194 from Kauhat/fix-composer
Fix user permissions issue when installing Composer in the workspace container
This commit is contained in:
commit
f2615b9ff2
@ -78,9 +78,14 @@ USER laradock
|
|||||||
#####################################
|
#####################################
|
||||||
|
|
||||||
# Add the composer.json
|
# Add the composer.json
|
||||||
ADD ./composer.json /home/laradock/.composer/composer.json
|
COPY ./composer.json /home/laradock/.composer/composer.json
|
||||||
|
|
||||||
# Check if global install need to be runned
|
# Make sure that ~/.composer belongs to laradock
|
||||||
|
USER root
|
||||||
|
RUN chown -R laradock:laradock /home/laradock/.composer
|
||||||
|
USER laradock
|
||||||
|
|
||||||
|
# Check if global install need to be ran
|
||||||
ARG COMPOSER_GLOBAL_INSTALL=true
|
ARG COMPOSER_GLOBAL_INSTALL=true
|
||||||
ENV COMPOSER_GLOBAL_INSTALL ${COMPOSER_GLOBAL_INSTALL}
|
ENV COMPOSER_GLOBAL_INSTALL ${COMPOSER_GLOBAL_INSTALL}
|
||||||
RUN if [ ${COMPOSER_GLOBAL_INSTALL} = true ]; then \
|
RUN if [ ${COMPOSER_GLOBAL_INSTALL} = true ]; then \
|
||||||
|
Loading…
Reference in New Issue
Block a user