Giter VIP home page Giter VIP logo

jarvusinnovations / emergence Goto Github PK

View Code? Open in Web Editor NEW
39.0 39.0 10.0 27.82 MB

Emergence is a NodeJS-powered server that provides a web interface for configuring and launching the services that power your website or application. It provides virtualized storage containers for your code and assets that are accessible via WebDAV and API. Each storage container maintains complete version history for all files and can be linked over the web to a parent container that files will be inherited from just-in-time.

Home Page: http://emr.ge

License: MIT License

Perl 0.33% JavaScript 35.69% Shell 7.37% HTML 0.23% PHP 55.26% Dockerfile 1.11%

emergence's People

Contributors

aharley40 avatar gitter-badger avatar hparadiz avatar jmealo avatar jtwiest avatar knightar avatar nbey avatar themightychris avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

emergence's Issues

config collections

Support matching collections in the filesystem in addition to .config.php files during the config phase of loading a class. A .config.php file will be loaded first if found, followed by all files in the matching collection in lexical order.

Use site/vfs prefix for 404 parent response caching

Caching 404 from parent sites currently uses a global cache key namespace to gain some efficiency from multiple sites on the same server sharing the status. This however puts the cache key outside the scope of tools for clearing the VFS or application cache for a site, requiring a full PHP restart to clear it.

Prefix the cache key the same way that file/collection caches are keyed, so that the "repair filesystem" task's clear cache action will clear out 404 caches too

Add Site in Firefox is Broken

Observed in Firefox 42.

Investigated a bit and found that the data is passing through alright but the Emergence instances isn't recognizing the data as json.

Add short connect timeout and retry to parent requests

  • Set CURLOPT_CONNECTTIMEOUT' in Emergence::executeRequest()` to something low like 1 or 2
  • Add $retries=1 parameter to Emergence::executeRequest() and have it return a re-invoktion of itselft with $retries- 1 if $retries > 0
  • Evaluate different default values of the timeout and retries on a test instance with simulated parent failures

automate postfix configuration

Mail handling has already been merged into Emergence/Skeleton but currently postfix has to be manually configured. A kernel service needs to be added to configure and launch postfix automatically.

special site-root handlers

Site::handleRequest should support special handlers in site-root:

  • _index - used when the route matches its parent collection
  • _notfound - used when a subpath was not found, the closest ancestor to the not found path is used
  • _all - handles all requests within current collection and down even if a closer handler would match

Minimally adapt kernel to use habitat for dependencies and process supervision

#46 contains the first approach to integrating emergence
The new approach will be to:

  • Continue installing emergence-kernel via npm install -g, so that both new machines can be initialized and old machines updated with the same command
  • The kernel will handle installing habitat
    • maybe run the habitat curl|bash when the kernel starts if hab isn't found in the path?
    • maybe use some sort of npm hook to do that from a package.json option when the kernel is globally installed?
    • maybe repackage habitat as an npm package so it can just be a dependency for the kernel that npm handles installing to .bin
  • The kernel will automate running hab commands
    • maybe just use a promise-based shell npm package to run hab commands
    • maybe repackage habitat as an npm package and expose async functions for each of the habitat commands we want that take node-ified options
  • generate a single json document config for the entire host, consisting of the /emergence/config.json base document with a "sites" key added containing an object mapping each site handle under /emergence/sites/* to the contents of its site.json
  • setup the config templates for each plan in https://github.com/JarvusInnovations/Emergence/tree/habitat/service-plans to generate from this shared mega-config tree
    • only the nginx config will loop through the "sites" list
    • we might want to remap services.plugins.myservice in legacy config.json to just services.myservice on load if plugins is detected the only key. Update the code that auto-generates new config.json to skip the plugins subkey going forward
  • start the habitat supervisor if needed
  • reimplement the start / stop functions for each of kernel-lib/services/* to load+start / stop via hab sup
  • query hab sup status for current service status on startup and when requested instead of using pid files and maintaining a started/stopped state internally
  • customize health check hooks for each service to do as complete a check as possible for being usable by emergence

Emergence replication / mirroring

Workflow:

Run emergence-slave-setup on the slave instance
The script should

  1. Creates an SSH account
  2. Create an SSH key
  3. Provide a script/command to run to add the slave on the master

Run emergence-master-setup on the slave instance

  1. The script will instruct you to run emergence-slave-setup first and to cut and paste the script/command.
  2. When you run the script/command it will connect via SSH to the slave instance and perform the following

SSL vhosts should include all hostnames

Currently SSL vhosts only get configured with the primary_hostname under the assumption that that's the only one that will work with the cert. Wildcard certs might be used that that support many of the alt hostnames, so all hostnames should be written to the SSL vhost to ensure the correct site gets resolved for those hostnames

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.