Giter Club home page Giter Club logo

maersk-line's Introduction

MAERSK LINE

Docker

Install docker for mac via the latest stable installation from docs.docker.com

Installation

  • You can directly clone to your directory using
    $ git clone -b 1.0 --depth 1 https://github.com/kewljuice/maersk-line
  • Browse to maersk-line folder in terminal
  • Check docker status bash docker-status.sh
  • Restart docker containers bash docker-restart.sh
  • Remove docker container and images bash docker-cleanup.sh
  • Init website bash website-install.sh
  • Remove website bash website-remove.sh
  • Update CiviCRM docker-compose run --rm build bash /var/www/civicrm-update.sh

Containers

  • NGiNX
  • PHP
  • Drupal
  • CIVIX
  • MySQL
  • phpMyAdmin

Browse

  • application: open browser and go to localhost:8080
    • administrator login: (admin/admin)
    • moderator login: (moderator/moderator)
  • phpyadmin: open browser and go to localhost:8181
    • root login: (root/root)

Components

  • Git Init/Branches
  • Drupal Installation/Configuration/3th party modules & themes
  • CiviCRM version 4.7.16

Uninstall

  • Complete docker containers & images (careful!!!)
    • Browse to maersk-line folder in terminal
    • Cleanup images and containers bash docker-cleanup.sh
  • Drupal/CiviCRM installation in container
    • Go to Drupal container docker exec -it docker_drupal_X sh bash
    • Go to /var/www/ folder cd /var/www
    • Execute cleanup script bash cleanup.sh

maersk-line's People

Contributors

kewljuice avatar

Watchers

 avatar

maersk-line's Issues

cleanup.sh deletes ALL images / containers

You do realize that if you execute cleanup.sh all images and containers will be removed, not only those specific to this project?

Just kidding, I saw it in the readme, however : this seems like a very dangerous thing to put in a shell script.

My advice would be to leave image / container maintenance to the user and to not try to offer 'management services' to your users.

I do not get the 'cleanup' of the drupal container

In essence, you should always see your Docker containers as ephemeral : meaning they only last a short time.

This means that, once a container served it's purpose, it should be removed from the system, unlike a VM, which can be re-used for other projects. Never forget : containers are like extended classes from your base images, and they can be moulded for whatever purpose you need them to perform. If you need another extended class you do not 'empty' the existing class and reuses it, you make a new class extended from the parent class (in this case the image).

A simple example : in webdev land you often need to load in a project in order to debug it. Why would you ever want to 'clear' an existing container in order to fill it with the new project to debug, when you can simply use the existing image and create a new container for that purpose?

In that regard, the cleanup.sh script of the docker drupal container seems pointless : is there ever going to be a reason you want an existing container (drupal container that is) emptied of it's civi / drupal installation?

If you need a new container for another project you simply change the docker-compose.yml file to suit your needs and create another, ready to use in another project. That is the real strength of Docker, the speed in which something like this can be achieved.

This is only my two cents on the subject, but it might be worth taking a deep look as to why the cleanup.sh would ever be necessary :)

status.sh

I do not understand quite clearly what the purpose of this shell script would be?

For instance :

  1. Checking versions is fine, but you should first check if the programs are installed (for instance, docker machine is quite unnecessary on Linux machines :) )

  2. Doing a "docker images" and a "docker ps -a" does not prove a thing : the amount of images / containers is irrelevant to the functioning of Docker (and might confuse users of this Docker instance, they will see their own images / containers)

I'm guessing this is just a helper script, but I would either mention this or completely remove it from the repo.

build.sh

Is there any specific reason why the images need to be built locally instead of downloaded from a online repo, like Docker Hub?

I'm only mentioning it because there doesn't seem to be a security risk involved, or project specific configuration 'embedded' into the image(s).

That way you can directly use docker-compose to build the images (if needed), instead of introducing a manual step.

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.