All Projects → redhat-developer-tooling → developer-platform-install

redhat-developer-tooling / developer-platform-install

Licence: Apache-2.0 license
Single Installer for all Red Hat Development Tools and more. Download it form Red Hat Developers Portal web site - http://developers.redhat.com/products/devsuite/overview/.

Programming Languages

javascript
184084 projects - #8 most used programming language
HTML
75241 projects
CSS
56736 projects
powershell
5483 projects

Projects that are alternatives of or similar to developer-platform-install

sloth-app
Sloth desktop app
Stars: ✭ 16 (-33.33%)
Mutual labels:  installer, electron-app
Installer
A simple standalone program which automates the installation, removal and maintenance of BetterDiscord.
Stars: ✭ 1,391 (+5695.83%)
Mutual labels:  installer, electron-app
Ng6 Starter
🆖 An AngularJS Starter repo for AngularJS + ES6 + Webpack
Stars: ✭ 1,933 (+7954.17%)
Mutual labels:  gulp, angular1
Scoop-Core
Shovel. Alternative, more advanced, and user-friendly implementation of windows command-line installer scoop.
Stars: ✭ 174 (+625%)
Mutual labels:  installer
project-manager-laravel
Project manager system - PHP and AngularJS
Stars: ✭ 17 (-29.17%)
Mutual labels:  gulp
twoobl
Blank theme for Elementor
Stars: ✭ 19 (-20.83%)
Mutual labels:  gulp
js-stack-from-scratch
🌺 Russian translation of "JavaScript Stack from Scratch" from the React-Theming developers https://github.com/sm-react/react-theming
Stars: ✭ 394 (+1541.67%)
Mutual labels:  gulp
AngularJS-ES6
No description or website provided.
Stars: ✭ 25 (+4.17%)
Mutual labels:  angular1
jill.py
A cross-platform installer for the Julia programming language
Stars: ✭ 202 (+741.67%)
Mutual labels:  installer
zap
⚡ Delightful AppImage package manager
Stars: ✭ 354 (+1375%)
Mutual labels:  installer
notion-linux-wrapper
Notion.so desktop application for Linux
Stars: ✭ 37 (+54.17%)
Mutual labels:  electron-app
chronobreak
Pomodoro timer made in Electron that emphasises replicating the original technique.
Stars: ✭ 22 (-8.33%)
Mutual labels:  electron-app
lnv-mobile-base
移动端开发脚手架-基于gulp的使用zepto、handlebars、sass并且带移动端适配方案(flexible.js)的前端工作流,旨在帮助移动端项目的开发
Stars: ✭ 41 (+70.83%)
Mutual labels:  gulp
mark.js
mark.js用于标记选中的文字,自定义插入标签
Stars: ✭ 27 (+12.5%)
Mutual labels:  gulp
alias
Resolve TypeScript import aliases and paths.
Stars: ✭ 19 (-20.83%)
Mutual labels:  gulp
fractal-starter-kit
Starter kit for Fractal with SCSS, Webpack, XO, sass-lint and Gulp
Stars: ✭ 22 (-8.33%)
Mutual labels:  gulp
Tasmota-specials
Tasmota unofficial firmware builds. Install via Tasmota WebInstaller
Stars: ✭ 54 (+125%)
Mutual labels:  installer
laravel-installer
Installer for Laravel 5.X
Stars: ✭ 47 (+95.83%)
Mutual labels:  installer
lead
Sink your streams.
Stars: ✭ 14 (-41.67%)
Mutual labels:  gulp
igni-core
UNSUPPORTED: An easy to use & featherlight CMS that shortcuts the bootstrapping of backend PHP + MySQL based projects. Developed in Laravel, it uses the latest PHP coding standards and library versions.
Stars: ✭ 13 (-45.83%)
Mutual labels:  gulp

Red Hat Development Suite Installer

This installer aims to produce ready to use development environment for Red Hat Container Development Kit on Windows and macOS platforms.

Deliverables

Build output is two platform specific executables: Online and Bundle installer. Online Installer is lightweight (approximately 50Mb) and it downloads everything during installation. Bundle Installer includes most of binary dependencies and downloads binaries that cannot be included during installation.

Windows

Both Installers are self extracting executable files made with 7-zip file archiver with a high compression ratio (7-Zip is licensed under the GNU LGPL license, more details on https://www.7zip.org).

macOS

Each Installer is a disk image (.dmg file) with macOS Application Bundle inside.

Architecture

This installer is desktop application for Windows and macOS built with Electron.

Building Installer

To build installer follow steps below for specific platform (please note that 'browser/images' and 'resources' folders contains graphical files for product logos and icons which are the copyrighted work of Red Hat).

Windows

  1. Download and install nvm for Windows from https://github.com/coreybutler/nvm-windows/. Pick the MSI installer.

  2. Install nodejs using

     nvm install 6.9.1
    
  3. Download and install Python 2.7.x for Windows from https://www.python.org/downloads/release/

  4. Edit your "Path" by going to the "System" Control Panel, "Advanced system settings", "Environment Variables". Add C:\Program Files\nodejs;C:\Users\<username>\App Data\Roaming\npm to the "Variable value".

    Note that your system might have an "AppData" (no space) instead of "App Data" (with space) folder, so make sure you use the correct path for your system.

  5. Download and install git for windows from https://github.com/git-for-windows/git/releases/tag/v2.11.0.windows.1

  6. Run git bash from Windows Start Menu

  7. In git bash windows clone installer repository by running

     git clone https://github.com/redhat-developer-tooling/developer-platform-install.git ~/Projects/developer-platform-install
    
  8. Then change current directory to repository root

     cd ~/Projects/developer-platform-install
    
  9. Install required dependencies with

     npm install
    
  10. Build installer executables with

    npm run dist
    

After build is finished ./dist folder should contain Windows executable files for On-line and Bundle Installers.

macOS

  1. Install git by running

     git
    

    from bash terminal and then follow the requests to install Xcode Development IDE

  2. Run git again to accept the license

  3. Install nvm (Nodejs Version Management) by running following shell script in bash terminal

     touch ~/.bash_profile
     curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.6/install.sh | bash
    

    then restart bash to pick up changes in your environment

  4. Install nodejs using nvm command

     nvm install v8.9.1
    
  5. Clone installer repository

     git clone https://github.com/redhat-developer-tooling/developer-platform-install.git ~/Projects/developer-platform-install
    
  6. Then change current directory to repository root

     cd ~/Projects/developer-platform-install
    
  7. Install required dependencies with

     npm install
    
  8. Build installer executables with

     npm run dist:mac
    

After build finishes ./dist folder should contain disk image files (.dmg) with macOS application packages for On-line and Bundle Installers.

Linux

  1. Install git by running

     sudo yum install git
    

from terminal

  1. Install nvm (Nodejs Version Management) by running following shell script in terminal

     touch ~/.bash_profile
     curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.32.1/install.sh | bash
    

then restart bash to pick up changes in your environment

  1. Install nodejs using nvm command

     nvm install 6.9.1
    
  2. Clone installer repository

     git clone https://github.com/redhat-developer-tooling/developer-platform-install.git ~/Projects/developer-platform-install
    
  3. Then change current directory to repository root

     cd ~/Projects/developer-platform-install
    
  4. Install required dependencies with

     npm install
    

Running the application

There are multiple ways how to run the installer.

  1. When fixing bugs and/or creating new features, run the application using

     npm start
    

    This way, you can open Chrome developer tools using Ctrl+Alt+I or reload application using Ctrl+R.

  2. Build a Windows binary and run it:

     npm run generate
     dist/win/DevelopmentSuiteInstaller-win32-x64/DevelopmentSuiteInstaller.exe
    
  3. Build a distribution Windows binary that downloads Vagrant, VirtualBox, DevStudio, etc. from the Internet (it will download about 1.6G):

     npm run package-simple
     dist/win/DevelopmentSuiteInstaller-win32-x64-*.exe
    
  4. Build a distribution Windows binary including almost all dependencies, except of Vagrant and VirtualBox (will download them):

     npm run package-bundle
     dist/win/DevelopmentSuiteInstaller-win32-x64-*-bundle.exe
    
  5. To build both installers in a single step:

     npm run dist
    

Running installer behind proxy

Proxy configuration details are available in this issue #1171.

Local build with clean up

If your npm install gets corrupted (or out of date) and you can't build, you can try cleaning leftover modules by deleting all dependencies and generated configuration files and installing them again:

rm -rf node_modules/
npm cache clean
npm install -g gulp
npm install

Then build as in the examples above.

Running unit tests

Unit tests are located in test/unit. To run all unit tests:

npm test

To run selected unit tests, you can grep any string from describe or it section of any test, e.g.:

npm test -- -g login
npm test -- --grep login

To run tests from specific file --spec-file parameter can be used to override default pattern to select files to run. Parameter value can be specific file name

npm test -- --spec-file test/unit/pages/account/controller-test.js

or globe pattern

npm test -- --spec-file=test/unit/pages/**/*.js

Unit tests code coverage calculated by Istanbul. By default it generates html and raw coverage reports. The report format can be overridden with --report parameter like shown below

npm test -- --report cobertura

To open html coverage report in your default browser after unit tests finished use --open-report option

npm test -- --spec-file=test/unit/pages/**/*.js --open-report

Running unit tests one by one for each installer module

gulp unit-test-1by1

If you experience this error when running unit tests

module.js:598
 return process.dlopen(module, path._makeLong(filename));
             ^

Error: The specified procedure could not be found.
\\?\C:\p\rh\dpi\node_modules\keytar\build\Release\keytar.node
   at Object.Module._extensions..node (module.js:598:18)

install 'keytar' module using npm

npm install keytar

Debugging unit tests

Add

debugger;

statement in test where you want debugger to stop after start. Set env variable NODE_PATH pointing to the project's root folder and run

node_modules\.bin\mocha.cmd --inspect --inspect-brk --compilers js:babel-core/register path/to/file-test.js

Running Angular protractor UI tests

UI tests located in 'test/ui'. To run all UI tests:

npm run ui-test

Developing Angular protractor UI tests

UI tests use protractor 'browser' global object and Jasmine testing framework.

Running System (e2e) tests

System tests located in the 'test/system' folder. These tests have requirements depending on the platform they are run on.

Windows

To run the tests successfully on Windows, you need to have 'Oracle Corporation' added to the list of trusted publishers (otherwise a modal dialog will interrupt the tests when installing VirtualBox). The tests need to be run by a user with administrative privileges.

When running the tests locally, use the following command:

npm run system-test -- --binary="path to a DevSuite Installer executable archive"

For CI environment a powershell script is available in 'test/system/windows/runTests.ps1':

powershell -file $devsuiteFolder/test/system/windows/runTests.ps1 -binary "path to sfx archive"

This script launches the tests with elevated privileges and copy the installation logs into the $devsuiteFolder for archivation in CI environment.

Debugging in Chrome Developer Tools

Run installer with

npm start

and then push Ctrl + Shift + I to show Chrome Developer Tools in current installer window

Testing online installer

With mock server for all downloaded recourses

In windows System Properties Setting Dialog add

DSI_REJECT_UNAUTHORIZED=false

to your user environment variables. Run notepad.exe as Administrator and add

127.0.0.1 developers.redhat.com

to C:\Windows\system32\Drivers\etec\hosts file.

Then download (VPN connection required) all requirements with

gulp prefetch-all

When download finished run http and https mock servers to mock developers.redhat.com with download-manager links. In separate windows run

node gulp-tasks/http-server.js

and then

node gulp-tasks/https-server.js

Now you are ready to test online installer. Start dist/win/DevelopmentSuiteInstaller-win32-x64-*.exe from package explorer. Mock http server always returns true for authentication requests to let you pass account information page, but if you plan to install and test CDK in DevStudio use your real Red Hat user name and password from developers.rdhat.com.

With mock server for download-manager resources only

In Windows System Properties Setting Dialog add

DSI_REJECT_UNAUTHORIZED=false
DM_STAGE_HOST=localhost

to your user environment variables.

Then download (VPN connection required) requirements with

gulp prefetch

When download finished run https mock servers to mimic developers.redhat.com with download-manager links. In separate windows execute

node gulp-tasks/https-server.js

Now you are ready to test online installer without actual bits published to download-manager. Start dist/win/DevelopmentSuiteInstaller-win32-x64-*.exe from package explorer and use it as you would normally do after release.

Running online installer with gulp

It is possible to run online installer right from your favorite terminal on windows or macOS.

Windows

On Windows if you running from cmd, powershell or git bash console and going to install components that is MSI installers please be sure you started console as Administrator. That is required because installer starts MSI installers in non-interactive mode and they will fail to run without Administrative privileges.

macOS

On macOS, installer may request administrative account credentials to continue. So you can run from any bash instance and installer will show request for account with rights to administer current machine.

Changing UserAgent string for HTTP(S) requests

If you are developer set DSI_TEST_AGENT to be any truthy string value to get original user agent string replaced with modified one to avoid interference with real installer usage stats.

Debugging GUI without running actual installation

If you are developing UI and do not really needed to install anything, you can go though all the steps quickly using --skip-install option when running installer with npm.

npm start -- --skip-install

Updating dependencies to latest

Most of dependencies declared with exact version. That is required to get reproducible build results. To move declared dependencies to latest available versions run command below, unit tests, UI tests, dist build and then send regular github.com pull request.

npm run update-deps
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].