The Cloudify Console provides User Interface for managing and analyzing Cloudify Manager.
The following requirements should be met prior starting the application:
nvm use
to set Node.js version compatible with this projectstage
cloudify
with cloudify
as passworddocker pull postgres
docker run --name postgres-cfy -e POSTGRES_PASSWORD=cloudify -e POSTGRES_USER=cloudify -e POSTGRES_DB=stage -p 5432:5432 -d postgres
To setup development environment and start the application follow the steps below.
Configuration
conf/me.json
file basing on conf/me.json.template
.<MANAGER_IP>
into real IP of your Cloudify Manager in that file.Dependencies installation
Run npm run beforebuild
to install application dependencies.
Database setup
Run cd backend && npm run db-migrate
to initialize database.
Application start
You can run the application by starting the stage backend server and starting webpack dev server serving client side:
In backend
folder, run npm run devStart
to start backend server
NOTE: you will need to have write permissions to /var/log/cloudify/stage
).
For more information and troubleshooting visit backend.
And also run npm run devServer
to start webpack dev server.
At this point you should have development environment configured and running. Open http://localhost:4000 page in your web-browser to see if application is running.
Changes in the source code shall be loaded to the development version of the application:
The project is written in TypeScript and is using project references to speed up type-checking of multiple subprojects.
Compilation results are stored in the tsc-dist
directory. Keep in mind those are only used by the TypeScript compiler
and are not used in the UI application. Keeping those files serves as a cache to speed up subsequent compilations.
When developing, make sure your IDE TypeScript plugin supports project references and is using the main tsconfig.json
file as the configuration file. If your IDE uses project-specific tsconfig.json
files
(e.g. app/tsconfig.json
for files in the app
directory), your IDE will be doing unnecessary
work compiling subprojects multiple times.
IDEs known to work with project references:
neovim LSP
It requires a project-specific config or some other way to point to the main tsconfig.json
.
See https://github.com/neovim/nvim-lspconfig/issues/940#issuecomment-848902408
You can create application package and deploy it on a remote Cloudify Manager server.
You can create either tarball package or RPM package.
To create tarball package:
npm run build
.npm run zip
. stage.tar.gz
file in repository main directory.To create RPM package:
build-rpm
job).To upload the package to the remote Cloudify Manager:
~/.ssh/cloudify.key
or explicitly define path to it: export SSH_KEY_PATH=<PATH>
.manager.ip
in conf/me.json
or by exporting environment variable: export MANAGER_IP=<MANAGER_IP>
.stage.tar.gz
) is built or explicitly define path to the tarball or RPM package: export STAGE_PACKAGE=<PATH>
.npm run upload
.http://<MANAGER_IP>
to see if application is running.Package tarball archive contains the following resources:
backend
- Stage Backend - whole backend folderconf
- configuration files (see Configuration for details)dist
- Stage Frontend - directory created by Webpack according to the production configuration
appData
- built-in application datawidgets
- built-in widgets
<widget-name>
- every widget has its own folder widget.js
- minified widget bundle file (+ gzip-compressed widget bundles)widget.js.gz
- (optional) gzip-compressed widget.js
README.md
- documentation filewidget.png
- widget thumbnailtemplates
- built-in templates - whole templates folder
pages
- built-in pages - whole templates/pages folder static
- static filesimages
- image filesfonts
- font filesjs
- JavaScript bundles
main.bundle.js
- bundle created from client-side application source code (+ gzip-compressed bundle)main.bundle.js
- gzip-compressed main.bundle.js
vendor.bundle.js
- bundle created from client-side application external dependenciesvendor.bundle.js.gz
- gzip-compressed vendor.bundle.js
index.html
- main HTML file (created from app/index.tmpl.html)userData
- user application data (empty in clean package)widgets
- custom widgets (empty in clean package)templates
- custom templates (empty in clean package)
pages
- custom pages (empty in clean package)RPM package has all the files present in tarball package. In addition all files from packaging/files directory are installed.
Go to test/README.md.
Source Code documentation
Documentation way-of-work
See this to learn how this project is documented.
To get community support join Cloudify Community Slack.