Support Yarn MANAGEMENT tool.
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
This commit is contained in:
parent
a2847316c4
commit
62e0f0443c
@ -11,6 +11,7 @@ services:
|
||||
- INSTALL_XDEBUG=false
|
||||
- INSTALL_MONGO=false
|
||||
- INSTALL_NODE=false
|
||||
- INSTALL_YARN=false
|
||||
- INSTALL_DRUSH=false
|
||||
- INSTALL_AEROSPIKE_EXTENSION=false
|
||||
- COMPOSER_GLOBAL_INSTALL=false
|
||||
|
@ -181,6 +181,30 @@ RUN if [ ${INSTALL_NODE} = true ]; then \
|
||||
echo '[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm' >> ~/.bashrc \
|
||||
;fi
|
||||
|
||||
#####################################
|
||||
# YARN:
|
||||
#####################################
|
||||
|
||||
USER laradock
|
||||
|
||||
ARG INSTALL_YARN=false
|
||||
ENV INSTALL_YARN ${INSTALL_YARN}
|
||||
|
||||
RUN if [ ${INSTALL_YARN} = true ]; then \
|
||||
curl -o- -L https://yarnpkg.com/install.sh | bash && \
|
||||
echo "" >> ~/.bashrc && \
|
||||
echo 'export PATH="$HOME/.yarn/bin:$PATH"' >> ~/.bashrc \
|
||||
;fi
|
||||
|
||||
# Add YARN binaries to root's .bashrc
|
||||
USER root
|
||||
|
||||
RUN if [ ${INSTALL_YARN} = true ]; then \
|
||||
echo "" >> ~/.bashrc && \
|
||||
echo 'export YARN_DIR="/home/laradock/.yarn"' >> ~/.bashrc && \
|
||||
echo 'export PATH="$YARN_DIR/bin:$PATH"' >> ~/.bashrc \
|
||||
;fi
|
||||
|
||||
#####################################
|
||||
# PHP Aerospike:
|
||||
#####################################
|
||||
|
Loading…
Reference in New Issue
Block a user