github.com/pachyderm/pachyderm@v1.13.4/doc/docs/1.9.x/reference/pachctl/pachctl_put_file.md (about)

     1  ## pachctl put file
     2  
     3  Put a file into the filesystem.
     4  
     5  ### Synopsis
     6  
     7  Put a file into the filesystem.  This supports a number of ways to insert data into pfs.
     8  
     9  ```
    10  pachctl put file <repo>@<branch-or-commit>[:<path/in/pfs>] [flags]
    11  ```
    12  
    13  ### Examples
    14  
    15  ```
    16  
    17  # Put data from stdin as repo/branch/path:
    18  $ echo "data" | pachctl put file repo@branch:/path
    19  
    20  # Put data from stdin as repo/branch/path and start / finish a new commit on the branch.
    21  $ echo "data" | pachctl put file -c repo@branch:/path
    22  
    23  # Put a file from the local filesystem as repo/branch/path:
    24  $ pachctl put file repo@branch:/path -f file
    25  
    26  # Put a file from the local filesystem as repo/branch/file:
    27  $ pachctl put file repo@branch -f file
    28  
    29  # Put the contents of a directory as repo/branch/path/dir/file:
    30  $ pachctl put file -r repo@branch:/path -f dir
    31  
    32  # Put the contents of a directory as repo/branch/dir/file:
    33  $ pachctl put file -r repo@branch -f dir
    34  
    35  # Put the contents of a directory as repo/branch/file, i.e. put files at the top level:
    36  $ pachctl put file -r repo@branch:/ -f dir
    37  
    38  # Put the data from a URL as repo/branch/path:
    39  $ pachctl put file repo@branch:/path -f http://host/path
    40  
    41  # Put the data from a URL as repo/branch/path:
    42  $ pachctl put file repo@branch -f http://host/path
    43  
    44  # Put the data from an S3 bucket as repo/branch/s3_object:
    45  $ pachctl put file repo@branch -r -f s3://my_bucket
    46  
    47  # Put several files or URLs that are listed in file.
    48  # Files and URLs should be newline delimited.
    49  $ pachctl put file repo@branch -i file
    50  
    51  # Put several files or URLs that are listed at URL.
    52  # NOTE this URL can reference local files, so it could cause you to put sensitive
    53  # files into your Pachyderm cluster.
    54  $ pachctl put file repo@branch -i http://host/path
    55  ```
    56  
    57  ### Options
    58  
    59  ```
    60    -c, --commit                    DEPRECATED: Put file(s) in a new commit.
    61    -f, --file strings              The file to be put, it can be a local file or a URL. (default [-])
    62        --header-records uint       the number of records that will be converted to a PFS 'header', and prepended to future retrievals of any subset of data from PFS; needs to be used with --split=(json|line|csv)
    63    -h, --help                      help for file
    64    -i, --input-file string         Read filepaths or URLs from a file.  If - is used, paths are read from the standard input.
    65    -o, --overwrite                 Overwrite the existing content of the file, either from previous commits or previous calls to 'put file' within this commit.
    66    -p, --parallelism int           The maximum number of files that can be uploaded in parallel. (default 10)
    67    -r, --recursive                 Recursively put the files in a directory.
    68        --split line                Split the input file into smaller files, subject to the constraints of --target-file-datums and --target-file-bytes. Permissible values are line, `json`, `sql` and `csv`.
    69        --target-file-bytes uint    The target upper bound of the number of bytes that each file contains; needs to be used with --split.
    70        --target-file-datums uint   The upper bound of the number of datums that each file contains, the last file will contain fewer if the datums don't divide evenly; needs to be used with --split.
    71  ```
    72  
    73  ### Options inherited from parent commands
    74  
    75  ```
    76        --no-color   Turn off colors.
    77    -v, --verbose    Output verbose logs
    78  ```
    79