Concept "Easy System Cloning (DSESC)"

From SMW CindyKate by dataspects
Component0272684347 / (Redirected from Concept "Easy System Cloning (DSESC)")
Jump to navigation Jump to search

DSESC · Backup · Restore · Clone

{{#compound_query:Component0272684347Property "-Has subobject" has a restricted application area and cannot be used as annotation property by a user.UseCaseMotivation;?HasDirection;?IsMotivating;?IsMotivatedBy;?HasReasoning
Property "-Has subobject" has a restricted application area and cannot be used as annotation property by a user.Concept "Easy System Cloning (DSESC)";?HasDirection;?IsMotivating;?IsMotivatedBy;?HasReasoning Property "-Has subobject" has a restricted application area and cannot be used as annotation property by a user.Concept "Easy System Cloning (DSESC)";?HasDirection;?IsMotivating;?IsMotivatedBy;?HasReasoning
Lua error in Module:Motivations at line 23: attempt to concatenate field 'hasReasoning' (a nil value).


HasMarketingPage "HasMarketingPage</br>" contains a listed "LF" character as part of the property label and has therefore been classified as invalid.

Background and Reasoning

Essentially Easy System Cloning is a

  • encrypted,
  • scheduled/ad hoc,
  • full/incremental,
  • local/offsite

Duplicity backup solution. See

How is this concept implemented?

Set up EasySystemCloning (DSESC) Backup on system servers

Set up EasySystemCloning (DSESC) Restore on computers that shall be able to clone/restore the system

Old: Component 998880

A system is cloned by user@workstation:/home/user/clone_my_system$ vagrant up. This requires your workstation to have the following software installed:

This functionality is based on /home/user/clone_my_system/Vagrantfile. This Vagrantfile specifies a number of aspects:

  1. Which Vagrant box (e.g. dataspects/ubuntu-1404-temp) will be used as the basis for the VirtualBox virtual machine into which the system will be cloned. In order not to have to adapt the box when making configurative changes to the system being cloned (e.g. adding MediaWiki extensions), the box shall be provisioned up to the Conceptual Layer "Infrastructure". Subsequent provisioning will be carried out by pertinent Ansible tasks specific to your environment and Duplicity modalities.
  2. Because of issues regarding "Warning: Authentication failure. Retrying... " after packaging box, the Vagrantfile uses config.ssh.username/password method to connect to the box at startup. Ideally this should happen using SSH keys.
  3. Connecting to the box is necessary in order to set up the shared folders as specified in the Vagrantfile. This functionality requires the box to run the correct version of the VirtualBox guest additions. In case your workstation upgrades its version of VirtualBox, the box' version of the VirtualBox guest additions need to be matched to the workstation's version of VirtualBox. The above mentioned vagrant-vbguest Vagrant plugin facilitates this process upon cloning a system. An alternative to this is to repackage the box after having installed the correct VirtualBox guest additions. Besides for development reasons, a shared folder is necessary if Duplicity snapshots are obtained through Dropbox, see

Functional Model

<mermaid2> graph LR

VGF["DSKMFSystem/Vagrantfile = 'ubuntu/bionic64'
config.vm.synced_folder '/home/user-on-host/Snapshots', '/home/user-on-vm/Snapshots'
config.vm.synced_folder '/home/user-on-host/DSKMFSystem', '/vagrant'"]

subgraph Step 0: Prepare

watch 'docker image ls ; docker container ls ; docker network ls'"]


subgraph start-docker-containers.ansible-playbook.yml

   DMN["docker network create \
myNetwork --driver bridge "] MDB["docker run \
--network myNetwork \
--name dsMariaDB \
-e MYSQL_ROOT_PASSWORD=my-secret-pw \
-d \
mariadb:10.3.6 "] MDBdf["Click for Dockerfile"] DRA["docker run \
-itd \
--network myNetwork \
-p 80:80 \
-v /path/to/wikiroot/on/vm:/path/to/wikiroot/in/container \
--name dsApache \
dataspects/apache "] DRAdf["Click for Dockerfile"]

end SDC -->|"starts"| DMN SDC -->|"starts"| MDB SDC -->|"starts"| DRA DRA -.- DRAdf MDB -.- MDBdf click DRAdf "" "Dockerfile" click MDBdf "" "Dockerfile"

subgraph Step 1: Execute


end VGF -->|"runs"| IDO VGF -->|"runs"| IRU VGF -->|"runs"| SDC VGF -->|"runs"| RDS

subgraph restore-duplicity-snapshot.ansible-playbook.yml

RESTORE_TARGET_DIRECTORY_URN=/path/to/wikiroot/on/vm ;
docker run \
--rm \
--user=$UID \
-v $PWD/.cache:/home/duplicity/.cache/duplicity \
-v $PWD/.gnupg:/home/duplicity/.gnupg \
-v $SOURCE_URL:/source/ \
-v $TARGET_DIRECTORY_URN:/target/:rw \
dataspects/duplicity \
duplicity \
--allow-source-mismatch \
--encrypt-key $ENCRYPT_KEY_ID \
file:///source/ /target/ "] DDUdf["Click for Dockerfile"]

end RDS -->|"runs"| DDU DDU -.- DDUdf click DDUdf "" "Dockerfile"

classDef shellCommand font-family:monospace; class DMN,DDU,MDB,DRA shellCommand </mermaid2>