diff --git a/ui/.env.local.example b/ui/.env.local.example index 55d2b97214d..0cd7d31af54 100644 --- a/ui/.env.local.example +++ b/ui/.env.local.example @@ -1 +1 @@ -API_URL=http://localhost:8080/client/api +CS_URL=http://localhost:8080 diff --git a/ui/README.md b/ui/README.md index 2d685d86b00..3e5063dbf94 100644 --- a/ui/README.md +++ b/ui/README.md @@ -4,22 +4,26 @@ A modern role-based progressive CloudStack UI based on VueJS and Ant Design. ![Primate Screenshot](docs/screenshot-dashboard.png) -## Env and dependencies +## Getting Started -- node -- webpack -- eslint -- @vue/cli ~3 +Install node: (Debian/Ubuntu) + + sudo apt-get install npm nodejs + +Install node: (CentOS/Fedora) + + curl -sL https://rpm.nodesource.com/setup_10.x | sudo bash - + sudo yum install nodejs Install tools and dependencies: - sudo apt-get install npm - sudo npm i -g npm@next - sudo npm i -g npm-check-updates + sudo npm install -g @vue/cli webpack eslint + sudo npm install -g npm@next + sudo npm install -g npm-check-updates ncu -u # optional: upgrade dependencies npm install -## Developing against CloudStack Env +## Development Override the default `API_URL` to a running CloudStack management server: @@ -73,6 +77,8 @@ eg: ### Attributions +Primate uses the following: + - [VueJS](https://vuejs.org/) - [Ant Design Spec](https://ant.design/docs/spec/introduce) - [Ant Design Vue](https://vue.ant.design/) diff --git a/ui/vue.config.js b/ui/vue.config.js index b2a2d4e0881..917ac722c50 100644 --- a/ui/vue.config.js +++ b/ui/vue.config.js @@ -91,8 +91,8 @@ module.exports = { devServer: { port: 5050, proxy: { - '/client/api': { - target: process.env.API_URL || 'http://localhost:8080/client/api', + '/client': { + target: process.env.CS_URL || 'http://localhost:8080', secure: false, ws: false, changeOrigin: true