Skip to content

Draft: Import tool to import group tree with projects

Kassio Borges requested to merge kassio/restoration-import-tool into master

this MR is not intended to be merged into master. This is a script to assist with resolving a data restore that the SRE team will copy directly into a console session.

What does this MR do?

Imports all groups and projects to a namespace from a bundle generated using the script in !40731 (closed).

Address the import portion of this issue #241705 (closed). This has been created to assist the SRE team with restoring some data as part of this request: #241379 (closed)

To make the import process simpler it's parsing the export files to define the root group path, also the path is used as the group name.

All the process is being done in a serial form for now. It's not the most efficient way to do it, but it's the simplest.

File Structure

Exported file

The unpacked structure of the file generated in the export script looks like this:

$ tree bundle
bundle
├── 2020-09-06_09-49-512_g1_export.tar.gz
└── projects
    ├── g1.1
    │   ├── g1.1.1
    │   │   ├── p1.tar.gz
    │   │   ├── p2.tar.gz
    │   │   └── p3.tar.gz
    │   ├── g1.1.2
    │   │   ├── p1.tar.gz
    │   │   ├── p2.tar.gz
    │   │   └── p3.tar.gz
    │   ├── p1.tar.gz
    │   ├── p2.tar.gz
    │   └── p3.tar.gz
    ├── g1.2
    │   ├── g1.2.1
    │   │   ├── p1.tar.gz
    │   │   ├── p2.tar.gz
    │   │   └── p3.tar.gz
    │   ├── g1.2.2
    │   │   ├── p1.tar.gz
    │   │   ├── p2.tar.gz
    │   │   └── p3.tar.gz
    │   ├── p1.tar.gz
    │   ├── p2.tar.gz
    │   └── p3.tar.gz
    ├── neoterm.tar.gz
    ├── p1.tar.gz
    ├── p2.tar.gz
    └── p3.tar.gz

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Edited by Josianne Hyson

Merge request reports

Loading