From 1f52fdd586e4ce61f5f5abdb9398e29f1dc2a96e Mon Sep 17 00:00:00 2001 From: Hiroshi Ichikawa Date: Fri, 20 Aug 2021 15:07:30 +0900 Subject: [PATCH] Change the backend port to 8080. (#798) This makes the setup easier since this is the default port. --- ui/README.md | 6 +++--- ui/webpack.dev.js | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ui/README.md b/ui/README.md index 76f74b7065..39e206bfc7 100644 --- a/ui/README.md +++ b/ui/README.md @@ -16,14 +16,14 @@ to get the dependencies for our React app. Once you have everything, the easiest way to develop the UI is to run two local servers: -1. Run the Django (backend) server as usual, at port 8000. +1. Run the Django (backend) server as usual, at port 8080 (default). 2. Enable the React UI support (currently disabled by default) in the backend by setting `enable_react_ui` config to True: ``` - $ ./tools/console localhost:8000 + $ ./tools/console localhost:8080 > config.set(enable_react_ui=True) ``` -3. Run the UI with `tools/ui run`. It will talk to the backend at port 8000 when +3. Run the UI with `tools/ui run`. It will talk to the backend at port 8080 when it needs to make API calls. There is currently an issue with uploaded photos: the Webpack dev server is not set up to proxy requests for photo URLs, but it also can't serve the photos on its own, so photos will not correctly appear diff --git a/ui/webpack.dev.js b/ui/webpack.dev.js index 325b42242b..a27827fe23 100644 --- a/ui/webpack.dev.js +++ b/ui/webpack.dev.js @@ -31,7 +31,7 @@ module.exports = merge(common, { contentBase: path.join(__dirname, 'static/'), proxy: { '/*/d/**': { - target: 'http://localhost:8000', + target: 'http://localhost:8080', secure: false } },