> For the complete documentation index, see [llms.txt](https://docs.tonic.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.tonic.ai/textual/textual-install-administer/configuring-textual/enable-and-configure-textual-features/textual-config-pipeline-upload.md).

# Setting the S3 bucket for file uploads and redactions

For a self-hosted instance, you configure an S3 bucket to use to store dataset files and individual files that you use the Textual SDK to redact. If an S3 bucket is not configured, then:

* The dataset and individual redacted files are stored in the Textual application database.
* You cannot use Amazon Textract for [PDF and image processing](/textual/textual-install-administer/configuring-textual/enable-and-configure-textual-features/textual-config-pdf-image.md). If you configured Textual to use Amazon Textract, Textual instead uses Tesseract.

The authentication credentials for the S3 bucket include:

* The AWS Region where the S3 bucket is located.
* An AWS access key that is associated with an IAM user or role.
* The secret key that is associated with the access key.

To provide the authentication credentials, you can either:

* Provide the values directly as environment variable values.
* Use the instance profile of the compute instance where Textual runs.

You can also optionally override the default encryption used by the S3 bucket.

For an example IAM role that has the required permissions, go to [Required IAM role permissions for Amazon S3](/textual/textual-install-administer/configuring-textual/enable-and-configure-textual-features/pipelines-example-iam-roles.md#file-upload-example-iam-role).

## Docker <a href="#pipeline-file-upload-docker" id="pipeline-file-upload-docker"></a>

### Connection settings <a href="#docker-s3-connection" id="docker-s3-connection"></a>

In **.env**, add the following settings:

* `SOLAR_INTERNAL_BUCKET_NAME= <S3 bucket path>`
* `AWS_DEFAULT_REGION= <AWS Region>`
* `AWS_ACCESS_KEY_ID= <AWS access key>`&#x20;
* `AWS_SECRET_ACCESS_KEY= <AWS secret key>`

If you use the instance profile of the compute instance, then only the bucket name is required.

### Encryption override <a href="#docker-s3-encryption" id="docker-s3-encryption"></a>

To override the default encryption, add:

`SOLAR_INTERNAL_BUCKET_S3_SERVER_SIDE_ENCRYPTION_TYPE= <S3 or Kms>`

If you set the encryption type to `Kms`, then also add:

`SOLAR_INTERNAL_BUCKET_S3_SERVER_SIDE_ENCRYPTION_KEY = <AWS KMS key ID, key ARN, or key alias>`

## Kubernetes <a href="#pipeline-file-upload-kubernetes" id="pipeline-file-upload-kubernetes"></a>

### Connection settings <a href="#kubernetes-s3-connection" id="kubernetes-s3-connection"></a>

In **values.yaml**, within `env: { }` under both `textual_api_server` and `textual_worker`, add the following settings:

* `SOLAR_INTERNAL_BUCKET_NAME` - S3 bucket path
* `AWS_DEFAULT_REGION` - AWS Region
* `AWS_ACCESS_KEY_ID` - AWS access key
* `AWS_SECRET_ACCESS_KEY` - AWS secret key

For example, if no other environment variables are defined:

```json
  env: {
        "SOLAR_INTERNAL_BUCKET_NAME": "<S3 bucket path>",
        "AWS_DEFAULT_REGION": "<AWS Region>",
        "AWS_ACCESS_KEY_ID": "<AWS access key>",
        "AWS_SECRET_ACCESS_KEY": "<AWS secret key>"
       }
```

If you use the instance profile of the compute instance, then only the bucket name is required.

### Encryption override <a href="#kubernetes-s3-encryption" id="kubernetes-s3-encryption"></a>

To override the default encryption, add:

`SOLAR_INTERNAL_BUCKET_S3_SERVER_SIDE_ENCRYPTION_TYPE` - Either `S3` or `Kms`.

If you set the encryption type to `Kms`, then also add:

`SOLAR_INTERNAL_BUCKET_S3_SERVER_SIDE_ENCRYPTION_KEY` -The AWS KMS key ID, key ARN, or key alias.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.tonic.ai/textual/textual-install-administer/configuring-textual/enable-and-configure-textual-features/textual-config-pipeline-upload.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
