tar

Description

  • Fetch a tar archive from a href
  • Verify tar archive is extracted on check action
  • Extract tar archive on fix action
  • Immutable boolean is used to know if extracted tar content can be modified on filesystem

Example rule

{
    "path": "/home/user/bin",
    "ref": "/some/path/to/file.tar",
    "immutable": "true"
}

Form definition

Desc: |
  Point to a tar archive.
Css: comp48

Outputs:
  -
    Dest: compliance variable
    Class: file
    Type: json
    Format: dict

Inputs:
  -
    Id: ref
    Label: Tar uri
    DisplayModeLabel: ref
    LabelCss: fa-map-marker
    Help: "Examples:
        /path/to/reference_file.tar
        safe://safe.uuid.8dc85529a2b13b4b.626172.tar
        http://server/path/to/reference_file.tar
        https://server/path/to/reference_file.tar
        ftp://server/path/to/reference_file.tar
        ftp://login:pass@server/path/to/reference_file.tar"
    Type: string
  -
    Id: path
    Label: Install path
    DisplayModeLabel: path
    LabelCss: fa-map-marker
    Mandatory: Yes
    Help: path to install the tar reference content to.
    Type: string
  -
    Id: immutable
    Label: Immutable
    DisplayModeLabel: immutable
    LabelCss: fa-lock
    Mandatory: Yes
    Help: "On : extracted tar archive must not be modified on filesystem
           Off: extracted tar archive contents on filesystem can be modified"
    Type: boolean