From 3fe18368bd7b0a1596bd6efaa3ec30f8be17d09d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?La=C3=A9rcio=20de=20Sousa?= Date: Tue, 11 Feb 2020 14:58:08 -0300 Subject: [PATCH] Added option to map vue-cli ports from workspace container --- DOCUMENTATION/content/documentation/index.md | 16 +++++++++++++--- docker-compose.yml | 2 ++ env-example | 2 ++ 3 files changed, 17 insertions(+), 3 deletions(-) diff --git a/DOCUMENTATION/content/documentation/index.md b/DOCUMENTATION/content/documentation/index.md index 91127676..5fbe085f 100644 --- a/DOCUMENTATION/content/documentation/index.md +++ b/DOCUMENTATION/content/documentation/index.md @@ -560,8 +560,14 @@ composer update ```bash phpunit ``` - - +``` +vue serve +``` +(browse the results at `http://localhost:[WORKSPACE_VUE_CLI_SERVE_HOST_PORT]`) +``` +vue ui +``` +(browse the results at `http://localhost:[WORKSPACE_VUE_CLI_UI_HOST_PORT]`) @@ -1890,7 +1896,11 @@ To install NPM VUE CLI in the Workspace container 2 - Search for the `WORKSPACE_INSTALL_NPM_VUE_CLI` argument under the Workspace Container and set it to `true` -3 - Re-build the container `docker-compose build workspace` +3 - Change `vue serve` port using `WORKSPACE_VUE_CLI_SERVE_HOST_PORT` if you wish to (default value is 8080) + +4 - Change `vue ui` port using `WORKSPACE_VUE_CLI_UI_HOST_PORT` if you wish to (default value is 8001) + +5 - Re-build the container `docker-compose build workspace` diff --git a/docker-compose.yml b/docker-compose.yml index 72e8645f..084aff4f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -150,6 +150,8 @@ services: - "dockerhost:${DOCKER_HOST_IP}" ports: - "${WORKSPACE_SSH_PORT}:22" + - "${WORKSPACE_VUE_CLI_SERVE_HOST_PORT}:8080" + - "${WORKSPACE_VUE_CLI_UI_HOST_PORT}:8000" tty: true environment: - PHP_IDE_CONFIG=${PHP_IDE_CONFIG} diff --git a/env-example b/env-example index 05358cf2..2503842a 100644 --- a/env-example +++ b/env-example @@ -159,6 +159,8 @@ WORKSPACE_INSTALL_FFMPEG=false WORKSPACE_INSTALL_GNU_PARALLEL=false WORKSPACE_INSTALL_AST=true WORKSPACE_AST_VERSION=1.0.3 +WORKSPACE_VUE_CLI_SERVE_HOST_PORT=8080 +WORKSPACE_VUE_CLI_UI_HOST_PORT=8001 ### PHP_FPM ###############################################