GithubHelp home page GithubHelp logo

isabella232 / ui-driver-skel Goto Github PK

View Code? Open in Web Editor NEW

This project forked from rancher/ui-driver-skel

0.0 0.0 0.0 347 KB

Skeleton Rancher UI driver for custom docker-machine drivers

License: Apache License 2.0

JavaScript 78.29% HTML 20.83% CSS 0.88%

ui-driver-skel's Introduction

ui-driver-skel

Skeleton Rancher UI driver for custom docker-machine drivers

Note: The Master branch works with Rancher 2.x+, if you are building a custom driver for Rancher 1.x use the 1.x branch

Setup

  • Fork this repository into your own account as ui-driver-DRIVERNAME
    • DRIVERNAME should be the name of the driver that you would give to docker-machine create --driver, e.g. "mycompany", "digitalocean", "vultr", etc.
  • Update the "name" in package.json to match
    • You should also update description, URLs, etc, but these aren't strictly required.
  • npm install

Development

This package contains a small web-server that will serve up the custom driver UI at http://localhost:3000/component.js. You can run this while developing and point the Rancher settings there.

  • npm start
  • The driver name can be optionally overridden: npm start -- --name=DRIVERNAME
  • The compiled files are viewable at http://localhost:3000.
  • Note: The development server does not currently automatically restart when files are changed.
  • Do not use the model.<drivername>Confg signature to access your driver config in the template file, use the config alias that is already setup in the component

Building

For other users to see your driver, you need to build it and host the output on a server accessible from their browsers.

  • npm run build
  • Copy the contents of the dist directory onto a webserver.
    • If your Rancher is configured to use HA or SSL, the server must also be available via HTTPS.

Using

  • Add a Machine Driver in Rancher 2.0 (Global -> Node Drivers)
    • Name: Your DRIVERNAME (see above).
    • Download URL: The URL for the driver binary (e.g. https://github.com/mycompany/docker-machine-mycompany/releases/download/v1.0.0/docker-machine-driver-mycompany-v1.0.0-linux-amd64.tar.gz)
    • Custom UI URL: The URL you uploaded the dist folder to, e.g. https://github.com/mycompany/ui-driver-mycompany/releases/download/v1.0.0/component.js)
  • Wait for the driver to become "Active"
  • Go to Clusters -> Add Cluster, your driver and custom UI should show up.

ui-driver-skel's People

Contributors

mxschmitt avatar onmomo avatar vincent99 avatar westlywright avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.