Update web dockerfile to use dev deps when building prod assets (#985)

* Update web dockerfile to use dev deps when building prod assets
* Don't re-run yarn install as pre-req for build/run/test

Signed-off-by: Kevin Lingerfelt <kl@buoyant.io>
This commit is contained in:
Kevin Lingerfelt 2018-05-23 10:31:53 -07:00 committed by GitHub
parent d0f0eecbc8
commit cb2415498f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 9 deletions

View File

@ -259,8 +259,7 @@ address of the public API server that's running in your docker environment:
```bash
docker-compose stop web
cd web
../bin/go-run . --api-addr=$DOCKER_IP:8085
bin/web run --api-addr=$DOCKER_IP:8085
```
#### 3. Connect to `public-api` in Kubernetes
@ -283,8 +282,7 @@ bin/web port-forward
Then connect the local web process to the forwarded port:
```bash
cd web
../bin/go-run . --api-addr=localhost:8085
bin/web run --api-addr=localhost:8085
```
### Webpack dev server

View File

@ -24,7 +24,7 @@ USAGE
}; function --help { -h ;}
function dev {
setup
build
while getopts "p:" opt; do
case "$opt" in
@ -36,7 +36,7 @@ function dev {
cd $ROOT/web/app && yarn webpack-dev-server --port $DEV_PORT &
cd $ROOT/web && \
../bin/go-run . --webpack-dev-server=http://localhost:$DEV_PORT
../bin/go-run . --webpack-dev-server=http://localhost:$DEV_PORT $*
}
function build {
@ -58,7 +58,7 @@ function run {
port-forward &
cd $ROOT/web
../bin/go-run .
../bin/go-run . $*
}
function setup {
@ -67,8 +67,6 @@ function setup {
}
function test {
setup
cd $ROOT/web/app
yarn karma start --single-run $*
}