File tree Expand file tree Collapse file tree
DOCUMENTATION/content/documentation Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1543,6 +1543,23 @@ Enabling Global Composer Install during the build for the container allows you t
15431543
15441544
15451545
1546+ <br >
1547+ <a name =" Magento-2-authentication-credentials " ></a >
1548+ ## Magento 2 authentication credential (composer install)
1549+
1550+ 1 - Open the ` .env ` file
1551+
1552+ 2 - Search for the ` WORKSPACE_COMPOSER_AUTH ` argument under the Workspace Container and set it to ` true `
1553+
1554+ 3 - Now add your credentials to ` workspace/auth.json `
1555+
1556+ 4 - Re-build the Workspace Container ` docker-compose build workspace `
1557+
1558+
1559+
1560+
1561+
1562+
15461563<br >
15471564<a name =" Install-Prestissimo " ></a >
15481565## Install Prestissimo
Original file line number Diff line number Diff line change @@ -78,6 +78,7 @@ services:
7878 - INSTALL_AEROSPIKE=${WORKSPACE_INSTALL_AEROSPIKE}
7979 - INSTALL_V8JS=${WORKSPACE_INSTALL_V8JS}
8080 - COMPOSER_GLOBAL_INSTALL=${WORKSPACE_COMPOSER_GLOBAL_INSTALL}
81+ - COMPOSER_AUTH=${WORKSPACE_COMPOSER_AUTH}
8182 - COMPOSER_REPO_PACKAGIST=${WORKSPACE_COMPOSER_REPO_PACKAGIST}
8283 - INSTALL_WORKSPACE_SSH=${WORKSPACE_INSTALL_WORKSPACE_SSH}
8384 - INSTALL_LARAVEL_ENVOY=${WORKSPACE_INSTALL_LARAVEL_ENVOY}
Original file line number Diff line number Diff line change @@ -82,6 +82,7 @@ DOCKER_SYNC_STRATEGY=native_osx
8282### WORKSPACE #############################################
8383
8484WORKSPACE_COMPOSER_GLOBAL_INSTALL=true
85+ WORKSPACE_COMPOSER_AUTH=false
8586WORKSPACE_COMPOSER_REPO_PACKAGIST=
8687WORKSPACE_INSTALL_NODE=true
8788WORKSPACE_NODE_VERSION=node
Original file line number Diff line number Diff line change @@ -118,6 +118,9 @@ USER root
118118# Add the composer.json
119119COPY ./composer.json /home/laradock/.composer/composer.json
120120
121+ # Add the auth.json for magento 2 credentials
122+ COPY ./auth.json /home/laradock/.composer/auth.json
123+
121124# Make sure that ~/.composer belongs to laradock
122125RUN chown -R laradock:laradock /home/laradock/.composer
123126
@@ -132,6 +135,15 @@ RUN if [ ${COMPOSER_GLOBAL_INSTALL} = true ]; then \
132135 composer global install \
133136;fi
134137
138+ # Check if auth file is disabled
139+ ARG COMPOSER_AUTH=false
140+ ENV COMPOSER_AUTH ${COMPOSER_AUTH}
141+
142+ RUN if [ ${COMPOSER_AUTH} = false ]; then \
143+ # remove the file
144+ rm /home/laradock/.composer/auth.json
145+ ;fi
146+
135147ARG COMPOSER_REPO_PACKAGIST
136148ENV COMPOSER_REPO_PACKAGIST ${COMPOSER_REPO_PACKAGIST}
137149
Original file line number Diff line number Diff line change 1+ {
2+ "http-basic" : {
3+ "repo.magento.com" : {
4+ "username" : " " ,
5+ "password" : " "
6+ }
7+ }
8+ }
You can’t perform that action at this time.
0 commit comments