Skip to content

Commit 36814a4

Browse files
caitlinwheelessnikcaitlinwheeless
authored
docs: DIA-1872: Add ADC doc in GCS connection (#7032)
Co-authored-by: nik <[email protected]> Co-authored-by: caitlinwheeless <[email protected]>
1 parent f18871a commit 36814a4

File tree

2 files changed

+21
-10
lines changed

2 files changed

+21
-10
lines changed

docs/source/guide/security.md

+7
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,13 @@ Data in Label Studio is stored in one or two places, depending on your deploymen
7575
- Project settings and configuration details are stored in Label Studio's internal database.
7676
- Input data (texts, images, audio files) is hosted by external data storage and provided to the Label Studio by using URI links. The data is not stored in Label Studio directly, the content is retrieved client-side only.
7777
- Project annotations are stored in the internal database, and optionally can be stored in a local file directory, a Redis database, or cloud storage buckets on Amazon Web Services (AWS), Google Cloud Platform (GCP), or Microsoft Azure.
78+
79+
80+
!!! info Tip
81+
There are several advanced security options for AWS and GCP storage, including:
82+
* [Application Default Credentials for GCP](storage#Application-Default-Credentials-for-enhanced-security-for-GCS) (on-prem only)
83+
* [IP filtering for GCP storage](storage#IP-filtering-for-enhanced-security-for-GCS)
84+
* [IP filtering and VPN for S3](storage#IP-Filtering-and-VPN-for-Enhanced-Security-for-S3-Storage)
7885

7986
### Secure database access
8087

docs/source/guide/storage.md

+14-10
Original file line numberDiff line numberDiff line change
@@ -532,12 +532,11 @@ In the Label Studio UI, do the following to set up the connection:
532532
- Enable **Treat every bucket object as a source file** if your bucket contains BLOB storage files such as JPG, MP3, or similar file types. This setting creates a URL for each bucket object to use for labeling, such as `gs://my-gcs-bucket/image.jpg`. Leave this option disabled if you have multiple JSON files in the bucket with one task per JSON file.
533533
- Choose whether to disable **Use pre-signed URLs**. If your tasks contain gs://... links, they must be pre-signed in order to be displayed in the browser.
534534
- Adjust the counter for how many minutes the pre-signed URLs are valid.
535-
8. In the **Google Application Credentials** field, add a JSON file with the GCS credentials you created to manage authentication for your bucket. You can also use the `GOOGLE_APPLICATION_CREDENTIALS` environment variable to specify this file. For example:
536-
```bash
537-
export GOOGLE_APPLICATION_CREDENTIALS=json-file-with-GCP-creds-23441-8f8sd99vsd115a.json
538-
```
535+
8. In the **Google Application Credentials** field, add a JSON file with the GCS credentials you created to manage authentication for your bucket.
536+
537+
**On-prem users:** Alternatively, you can use the `GOOGLE_APPLICATION_CREDENTIALS` environment variable and/or set up Application Default Credentials, so that users do not need to configure credentials manually. See [Application Default Credentials for enhanced security](#Application-Default-Credentials-for-enhanced-security-for-GCS) below.
539538
9. Click **Add Storage**.
540-
10. Repeat these steps for **Target Storage** to sync completed data annotations to a bucket.
539+
10. Repeat these steps for **Target Storage** to sync completed data annotations to a bucket.
541540

542541
After adding the storage, click **Sync** to collect tasks from the bucket, or make an API call to [sync import storage](/api#operation/api_storages_gcs_sync_create).
543542

@@ -546,8 +545,17 @@ You can also create a storage connection using the Label Studio API.
546545
- See [Create new import storage](/api#operation/api_storages_gcs_create) then [sync the import storage](/api#operation/api_storages_gcs_sync_create).
547546
- See [Create export storage](/api#operation/api_storages_export_gcs_create) and after annotating, [sync the export storage](/api#operation/api_storages_export_gcs_sync_create).
548547

548+
### Application Default Credentials for enhanced security for GCS
549+
550+
If you use Label Studio on-premises with Google Cloud Storage, you can set up [Application Default Credentials](https://cloud.google.com/docs/authentication/provide-credentials-adc) to provide cloud storage authentication globally for all projects, so users do not need to configure credentials manually.
551+
552+
The recommended way to to do this is by using the `GOOGLE_APPLICATION_CREDENTIALS` environment variable. For example:
549553

550-
### IP Filtering for Enhanced Security for GCS storage
554+
```bash
555+
export GOOGLE_APPLICATION_CREDENTIALS=json-file-with-GCP-creds-23441-8f8sd99vsd115a.json
556+
```
557+
558+
### IP filtering for enhanced security for GCS
551559

552560
Google Cloud Storage offers [bucket IP filtering](https://cloud.google.com/storage/docs/ip-filtering-overview) as a powerful security mechanism to restrict access to your data based on source IP addresses. This feature helps prevent unauthorized access and provides fine-grained control over who can interact with your storage buckets.
553561

@@ -624,10 +632,6 @@ gcloud alpha storage buckets update gs://BUCKET_NAME --clear-ip-filter
624632

625633
</details>
626634

627-
#### Application Default Credentials as Advanced Security Approach
628-
629-
**Google ADC**: If you use Label Studio on-premises with Google Cloud Storage, you can set up [Application Default Credentials](https://cloud.google.com/docs/authentication/provide-credentials-adc) to provide cloud storage authentication globally for all projects, so users do not need to configure credentials manually.
630-
631635

632636
## Microsoft Azure Blob storage
633637

0 commit comments

Comments
 (0)