Download and extract the "mongod" binary

Hierarchy

  • MongoBinaryDownload

Constructors

Properties

_downloadingUrl?: string
binaryOpts: Required<MongoBinaryOpts>

These options are kind of raw, they are not run through DryMongoBinary.generateOptions

Methods

  • Extract a .tar.gz archive

    Parameters

    • mongoDBArchive: string

      Archive location

    • extractPath: string

      Directory to extract to

    • filter: ((file) => boolean)

      Method to determine which files to extract

        • (file): boolean
        • Parameters

          • file: string

          Returns boolean

    Returns Promise<void>

  • Extract a .zip archive

    Parameters

    • mongoDBArchive: string

      Archive location

    • extractPath: string

      Directory to extract to

    • filter: ((file) => boolean)

      Method to determine which files to extract

        • (file): boolean
        • Parameters

          • file: string

          Returns boolean

    Returns Promise<void>

  • Downlaod given httpOptions to tempDownloadLocation, then move it to downloadLocation

    Parameters

    • url: URL
    • httpOptions: RequestOptions

      The httpOptions directly passed to https.get

    • downloadLocation: string

      The location the File should be after the download

    • tempDownloadLocation: string

      The location the File should be while downloading

    Returns Promise<string>

  • Download MD5 file and check it against the MongoDB Archive

    Parameters

    • urlForReferenceMD5: string

      URL to download the MD5

    • mongoDBArchive: string

      The MongoDB Archive file location

    Returns Promise<undefined | boolean>

    if "checkMD5" is falsey

    Throws

    if the md5 check failed

Generated using TypeDoc