# Google Cloud Notebooks V1 Client - Class DiagnosticConfig (1.1.3)

1.1.3 (latest) 1.1.2 1.0.5 0.7.5 0.6.2 0.5.0 0.4.1 0.3.6 Reference documentation and code samples for the Google Cloud Notebooks V1 Client class DiagnosticConfig.

Defines flags that are used to run the diagnostic tool

Generated from protobuf message `google.cloud.notebooks.v1.DiagnosticConfig`

## Namespace

Google \\ Cloud \\ Notebooks \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ gcs_bucket` | `string` Required. User Cloud Storage bucket location (REQUIRED). Must be formatted with path prefix (`gs://$GCS_BUCKET`). Permissions: User Managed Notebooks: - storage.buckets.writer: Must be given to the project's service account attached to VM. Google Managed Notebooks: - storage.buckets.writer: Must be given to the project's service account or user credentials attached to VM depending on authentication mode. Cloud Storage bucket Log file will be written to `gs://$GCS_BUCKET/$RELATIVE_PATH/$VM_DATE_$TIME.tar.gz` |
| `↳ relative_path` | `string` Optional. Defines the relative storage path in the Cloud Storage bucket where the diagnostic logs will be written: Default path will be the root directory of the Cloud Storage bucket (`gs://$GCS_BUCKET/$DATE_$TIME.tar.gz`) Example of full path where Log file will be written: `gs://$GCS_BUCKET/$RELATIVE_PATH/` |
| `↳ repair_flag_enabled` | `bool` Optional. Enables flag to repair service for instance |
| `↳ packet_capture_flag_enabled` | `bool` Optional. Enables flag to capture packets from the instance for 30 seconds |
| `↳ copy_home_files_flag_enabled` | `bool` Optional. Enables flag to copy all `/home/jupyter` folder contents |

### getGcsBucket

Required. User Cloud Storage bucket location (REQUIRED).

Must be formatted with path prefix (`gs://$GCS_BUCKET`).
Permissions:
User Managed Notebooks:

- storage.buckets.writer: Must be given to the project's service account attached to VM. Google Managed Notebooks:
- storage.buckets.writer: Must be given to the project's service account or user credentials attached to VM depending on authentication mode. Cloud Storage bucket Log file will be written to `gs://$GCS_BUCKET/$RELATIVE_PATH/$VM_DATE_$TIME.tar.gz`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setGcsBucket

Required. User Cloud Storage bucket location (REQUIRED).

Must be formatted with path prefix (`gs://$GCS_BUCKET`).
Permissions:
User Managed Notebooks:

- storage.buckets.writer: Must be given to the project's service account attached to VM. Google Managed Notebooks:
- storage.buckets.writer: Must be given to the project's service account or user credentials attached to VM depending on authentication mode. Cloud Storage bucket Log file will be written to `gs://$GCS_BUCKET/$RELATIVE_PATH/$VM_DATE_$TIME.tar.gz`

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getRelativePath

Optional. Defines the relative storage path in the Cloud Storage bucket
where the diagnostic logs will be written: Default path will be the root
directory of the Cloud Storage bucket
(`gs://$GCS_BUCKET/$DATE_$TIME.tar.gz`)
Example of full path where Log file will be written:
`gs://$GCS_BUCKET/$RELATIVE_PATH/`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setRelativePath

Optional. Defines the relative storage path in the Cloud Storage bucket
where the diagnostic logs will be written: Default path will be the root
directory of the Cloud Storage bucket
(`gs://$GCS_BUCKET/$DATE_$TIME.tar.gz`)
Example of full path where Log file will be written:
`gs://$GCS_BUCKET/$RELATIVE_PATH/`

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getRepairFlagEnabled

Optional. Enables flag to repair service for instance

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### setRepairFlagEnabled

Optional. Enables flag to repair service for instance

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getPacketCaptureFlagEnabled

Optional. Enables flag to capture packets from the instance for 30 seconds

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### setPacketCaptureFlagEnabled

Optional. Enables flag to capture packets from the instance for 30 seconds

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCopyHomeFilesFlagEnabled

Optional. Enables flag to copy all `/home/jupyter` folder contents

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### setCopyHomeFilesFlagEnabled

Optional. Enables flag to copy all `/home/jupyter` folder contents

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |