pipelines/frontend
Kirin Patel 7b442f4a54 Created extensible code editor based on react-ace (#1855)
* Created extensible code editor based on react-ace

* Installed dependencies

* Updated unit tests for Editor.tsx to test placeholder and value in simplified manner

* Updated Editor unit tests to use snapshot testing where applicable
2019-08-20 18:27:19 -07:00
..
.vscode Initial commit of the kubeflow/pipeline project. 2018-11-02 14:02:31 -07:00
__mocks__ Initial commit of the kubeflow/pipeline project. 2018-11-02 14:02:31 -07:00
backstop_data Initial commit of the kubeflow/pipeline project. 2018-11-02 14:02:31 -07:00
mock-backend Fix run duration bug (#1827) 2019-08-15 19:52:34 -07:00
public updated favicon to monochrome color (#118) 2018-11-06 20:09:17 -08:00
server Fix github security alert. (#1798) 2019-08-11 14:25:10 -07:00
src Created extensible code editor based on react-ace (#1855) 2019-08-20 18:27:19 -07:00
third_party Frontend - Show customized task display names (#1463) 2019-06-06 17:36:32 -07:00
.gitignore Initial commit of the kubeflow/pipeline project. 2018-11-02 14:02:31 -07:00
Dockerfile Removes redundant npm install from FE Dockerfile (#1332) 2019-05-14 21:28:16 -07:00
OWNERS Remove yebrahim from approvers/reviewers (#1787) 2019-08-09 12:22:52 -07:00
README.md Update swagger codegen version (#839) 2019-02-21 12:21:38 -08:00
analyze_bundle.js Initial commit of the kubeflow/pipeline project. 2018-11-02 14:02:31 -07:00
backstop.json Initial commit of the kubeflow/pipeline project. 2018-11-02 14:02:31 -07:00
backstop.ts Initial commit of the kubeflow/pipeline project. 2018-11-02 14:02:31 -07:00
gen_licenses.js Initial commit of the kubeflow/pipeline project. 2018-11-02 14:02:31 -07:00
package-lock.json Created extensible code editor based on react-ace (#1855) 2019-08-20 18:27:19 -07:00
package.json Created extensible code editor based on react-ace (#1855) 2019-08-20 18:27:19 -07:00
swagger-config.json Initial commit of the kubeflow/pipeline project. 2018-11-02 14:02:31 -07:00
tsconfig.json Updates frontend to Typescript to 3.3.1 (#772) 2019-02-14 11:54:45 -08:00
tsconfig.prod.json Initial commit of the kubeflow/pipeline project. 2018-11-02 14:02:31 -07:00
tsconfig.test.json Initial commit of the kubeflow/pipeline project. 2018-11-02 14:02:31 -07:00
tslint.json Require full function signatures (#136) 2018-11-08 11:58:19 -08:00

README.md

Kubeflow Pipelines Management Frontend

Develop: You need npm, install dependencies using npm install.

If you made any changes to protos (see backend/README), you'll need to regenerate the Typescript client library from swagger. We use swagger-codegen-cli@2.4.1, which you can get here. Make sure the jar file is somewhere on your path with the name swagger-codegen-cli.jar, then run npm run apis.

You can then do npm start to run a static file server at port 3000 that watches the source files. This also adds a mock backend api server handler to webpack-dev-server so it can serve basic api calls, as well as a mock webserver to handle the Single Page App requests, which redirects api requests to the aforementioned mock api server. For example, requesting the pipelines page sends a fetch request to http://localhost:3000/apis/v1beta1/pipelines, which is proxied by the webserver to the api server at http://localhost:3001/apis/v1beta1/pipelines, which will return the list of pipelines currently defined in the mock database.

Production Build: You can do npm run build to build the frontend code for production, which creates a ./dist directory with the minified bundle. You can test this bundle using server/server.js. Note you need to have an API server running, which you can then feed its address (host + port) as environment variables into server.js. See the usage instructions in that file for more.

The mock API server and the mock webserver can still be used with the production UI code by running npm run mock:api and npm run mock:server.

Container Build:

You can also do npm run docker if you have docker installed to build an image containing the production bundle and the server pieces. In order to run this image, you'll need to port forward 3000, and pass the environment variables ML_PIPELINE_SERVICE_HOST and ML_PIPELINE_SERVICE_PORT with the details of the API server, which you can run using npm run api separately.