> ## Documentation Index
> Fetch the complete documentation index at: https://docs.chronosphere.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Files

In addition to the [YAML configuration file](/ingest/pipeline/v2/configure/config-files)
that govern a pipeline's settings, you can optionally add other kinds of files
to pipelines, such as [parsers](/ingest/pipeline/v2/build/parsers), certificates, and
[custom Lua](/ingest/pipeline/processing-rules/custom-lua) scripts.

<Note>
  Due to Kubernetes [ConfigMap](https://kubernetes.io/docs/concepts/configuration/configmap/)
  storage limitations, the total size of a pipeline and its associated resources
  can't exceed 1 MiB. This limit includes the combined size of
  [configuration files](/ingest/pipeline/v2/configure/config-files), [secrets](/ingest/pipeline/v2/configure/secrets),
  [parsers](/ingest/pipeline/v2/build/parsers), and any other files.
</Note>

## Add a file to a pipeline

To add a file to a pipeline, use one of these methods:

<Tabs>
  <Tab title="Web interface" id="add-file-pipeline-ui">
    1. Sign in to [Telemetry Pipeline](https://core.calyptia.com/).
    2. Open the project that contains the pipeline that you want to add a file to.
    3. Go to **Core Instances**, then click the name of the Core Instance associated
       with the pipeline that you want to add a file to.
    4. Under **Data Pipelines**, click the name of the pipeline that you want to add
       a file to.
    5. Click <Icon icon="square-pen" /> **Advanced Settings**.
    6. Under **Pipeline Files**, click **Upload File**.
    7. Use one of these methods to upload a file:
       * Click **Select File** to choose a file from your device.
       * Enter a value in **File name** field and add content to the large text field to create
         a new file with that name and content.
    8. Optional: To encrypt your file, select the **Encrypt file** checkbox.
    9. Click **Upload File**.
  </Tab>

  <Tab title="Pipeline CLI" id="add-file-pipeline-cli">
    Run the following [Pipeline CLI](/ingest/pipeline/pipeline-cli) command:

    ```shell theme={null}
    calyptia create pipeline_file --pipeline PIPELINE --file FILEPATH
    ```

    Replace the following:

    * *`PIPELINE`*: The name or [unique ID](/ingest/pipeline/v2/configure/metadata#get-pipeline-ids)
      of your pipeline.
    * *`FILEPATH`*: The path to the file to add, relative to your current directory.

    To encrypt your file, add the `--encrypt-files` flag.
  </Tab>
</Tabs>

## Add a file to a Core Instance

<Note>
  Adding a file to a Core Instance doesn't circumvent the 1 MiB resource limit
  for pipelines. If you add a file to a Core Instance, that file becomes a resource
  for every pipeline associated with that Core Instance, which increases the resource
  utilization for each pipeline accordingly.
</Note>

You can also add a file to a [Core Instance](/ingest/pipeline/v2/concepts#core-operators-and-core-instances),
which makes that file available to all pipelines associated with that Core Instance. To do
so, use one of these methods:

<Tabs>
  <Tab title="Web interface" id="add-file-instance-ui">
    1. Sign in to [Telemetry Pipeline](https://core.calyptia.com/).
    2. Open the project that contains the Core Instance that you want to add a file to.
    3. Go to **Core Instances**, then click the name of the Core Instance that
       you want to add a file to.
    4. Click <Icon icon="square-pen" /> **Advanced Settings**.
    5. Under **Pipeline Files**, click **Upload File**.
    6. Use one of these methods to upload a file:
       * Click **Select File** to choose a file from your device.
       * Enter a value in **File name** field and add content to the large text field to create
         a new file with that name and content.
    7. Optional: To encrypt your file, select the **Encrypt file** checkbox.
    8. Click **Upload File**.
  </Tab>

  <Tab title="Pipeline CLI" id="add-file-instance-cli">
    Run the following [Pipeline CLI](/ingest/pipeline/pipeline-cli) command:

    ```shell theme={null}
    calyptia create core_instance_file --core-instance INSTANCE --file FILEPATH
    ```

    Replace the following:

    * *`INSTANCE`*: The name of your Core Instance.
    * *`FILEPATH`*: The path to the file to add, relative to your current directory.

    To encrypt your file, add the `--encrypt-files` flag.
  </Tab>
</Tabs>

## Reference a file

After you've added a file to a pipeline, you can reference it in a
pipeline's [configuration file](/ingest/pipeline/v2/configure/config-files) by using the
following variable:

```text theme={null}
{{ files.FILENAME }}
```

Replace *`FILENAME`* with the name of your file.

## File encryption

For encrypted files, Telemetry Pipeline uses RSA‑OAEP encryption with a 2048-bit key.
Files are unencrypted by default, but you can choose to encrypt a file when you
add to it a pipeline or Core Instance.
