GithubHelp home page GithubHelp logo

binsky08 / docker-demo-site Goto Github PK

View Code? Open in Web Editor NEW

This project forked from animalillo/docker-demo-site

0.0 1.0 0.0 1.38 MB

A site to create a self destructing demo of your web app. Example:

Home Page: https://demo.passman.cc

License: GNU Affero General Public License v3.0

Shell 0.23% JavaScript 0.13% PHP 99.03% CSS 0.28% HTML 0.32% ApacheConf 0.01%

docker-demo-site's Introduction

Docker demo Site

With this tool you can easeily get a demo server for your awesome web application up and running very easily. Just setup your desired docker to run all the services for your application and feed that docker to this application.

This will create docker instances, open the docker port to the public and then destroy it and close that port after a given time.

Re-captcha keeps it safe from bot abuse and per-ip instance keeps it safe of human abuse, also adding a neat way of returning to your instance if you accidentally close the browser.

This simplifies the development of demo sites a lot:

  • You don't need to worry about cleaning your database and restoring bacups.
  • You don't need to worry about cleaning up user created files or uploads.
  • You don't need to worry about any system changes made by the application.

Enjoy!

Setup

  1. Site and daemon main configuration:

cd application/config/

cp config.php.example config.php

cp database.php.example daabase.php

cd ../../

  1. Main configuration:
  • Edit application/config/databaser.php to your desired database setup
  • Edit application/config/config.php to reflect your site url. Mind the $['docker_command'] changing it to the appropiate one for your demo needs.
  1. Setup composer dependencies

cd application/helpers/composer

./composerh.phar install

cd ../../../

  1. Setup daemon configuration:

cp daemon_config.example daemon_config

  1. Edit daemon_config variables to reflect your desired setup

  2. Optional: Setup init script

sudo ./daemon.sh install

  1. Congratulations! Everything is ready for your demos to run on demand!

To run the daemon

  • development run

    sudo php index.php Daemon

  • production run

    sudo ./daemon.sh daemon

  • If installed as init script, it will autostart at boot time

    service demo_site start

Uninstalling the init script

sudo ./daemon.sh uninstall

docker-demo-site's People

Contributors

animalillo avatar brantje avatar

Watchers

 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.