config info in doc (#3796)
<!-- PR description--> - Use single inverted comma instead of double inverted comma in Powershell env vars. - Update config file information in docs. #### Does this PR need a docs update or release note? - [ ] ⛔ No #### Type of change <!--- Please check the type of change your PR introduces: ---> - [ ] 🗺️ Documentation #### Issue(s) <!-- Can reference multiple issues. Use one of the following "magic words" - "closes, fixes" to auto-close the Github issue. --> * https://github.com/alcionai/corso/issues/3522 #### Test Plan <!-- How will this be tested prior to merging.--> - [ ] 💪 Manual - [ ] ⚡ Unit test - [ ] 💚 E2E
This commit is contained in:
parent
99d6d42919
commit
49f6f8c337
@ -10,6 +10,13 @@ Two things are needed to configure Corso:
|
|||||||
* Environment variables containing configuration information
|
* Environment variables containing configuration information
|
||||||
* A directory for Corso to store its configuration file
|
* A directory for Corso to store its configuration file
|
||||||
|
|
||||||
|
Apart from Environment variables configuration information can also be provided from flags or configuration files.
|
||||||
|
Corso uses the following priority order for configuration:
|
||||||
|
|
||||||
|
1. Flags values
|
||||||
|
2. Environment variables
|
||||||
|
3. Configuration File information
|
||||||
|
|
||||||
## Environment variables
|
## Environment variables
|
||||||
|
|
||||||
Three distinct pieces of configuration are required by Corso:
|
Three distinct pieces of configuration are required by Corso:
|
||||||
@ -34,15 +41,15 @@ alternate ways to pass AWS credentials.
|
|||||||
Ensure that all of the above environment variables are defined in your Powershell environment.
|
Ensure that all of the above environment variables are defined in your Powershell environment.
|
||||||
|
|
||||||
```powershell
|
```powershell
|
||||||
$Env:AWS_ACCESS_KEY_ID = "..."
|
$Env:AWS_ACCESS_KEY_ID = '...'
|
||||||
$Env:AWS_SECRET_ACCESS_KEY = "..."
|
$Env:AWS_SECRET_ACCESS_KEY = '...'
|
||||||
$Env:AWS_SESSION_TOKEN = ""
|
$Env:AWS_SESSION_TOKEN = ""
|
||||||
|
|
||||||
$Env:AZURE_CLIENT_ID = "..."
|
$Env:AZURE_CLIENT_ID = '...'
|
||||||
$Env:AZURE_TENANT_ID = "..."
|
$Env:AZURE_TENANT_ID = '...'
|
||||||
$Env:AZURE_CLIENT_SECRET = "..."
|
$Env:AZURE_CLIENT_SECRET = '...'
|
||||||
|
|
||||||
$Env:CORSO_PASSPHRASE = "CHANGE-ME-THIS-IS-INSECURE"
|
$Env:CORSO_PASSPHRASE = 'CHANGE-ME-THIS-IS-INSECURE'
|
||||||
```
|
```
|
||||||
|
|
||||||
</TabItem>
|
</TabItem>
|
||||||
@ -105,12 +112,48 @@ To create the environment variables file, you can run the following command:
|
|||||||
By default, Corso stores its configuration file (`.corso.toml`) in the user's home directory.
|
By default, Corso stores its configuration file (`.corso.toml`) in the user's home directory.
|
||||||
The location of the configuration file can be specified using the `--config-file` option.
|
The location of the configuration file can be specified using the `--config-file` option.
|
||||||
|
|
||||||
|
The config file can also be used to provide other configuration information like Azure and AWS credentials as mentioned below:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# AWS configs
|
||||||
|
aws_access_key_id = '...'
|
||||||
|
aws_secret_access_key = '...'
|
||||||
|
aws_session_token = '...'
|
||||||
|
|
||||||
|
# M365 config
|
||||||
|
account_provider = '...'
|
||||||
|
azure_tenantid = '...'
|
||||||
|
azure_client_id = '...'
|
||||||
|
azure_secret = '...'
|
||||||
|
|
||||||
|
# Corso passphrase
|
||||||
|
passphrase = '...'
|
||||||
|
```
|
||||||
|
|
||||||
</TabItem>
|
</TabItem>
|
||||||
<TabItem value="unix" label="Linux/macOS">
|
<TabItem value="unix" label="Linux/macOS">
|
||||||
|
|
||||||
By default, Corso stores its configuration file (`.corso.toml`) in the user's home directory.
|
By default, Corso stores its configuration file (`.corso.toml`) in the user's home directory.
|
||||||
The location of the configuration file can be specified using the `--config-file` option.
|
The location of the configuration file can be specified using the `--config-file` option.
|
||||||
|
|
||||||
|
The config file can also be used to provide other configuration information like Azure and AWS credentials as mentioned below:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# AWS configs
|
||||||
|
aws_access_key_id = '...'
|
||||||
|
aws_secret_access_key = '...'
|
||||||
|
aws_session_token = '...'
|
||||||
|
|
||||||
|
# M365 config
|
||||||
|
account_provider = '...'
|
||||||
|
azure_tenantid = '...'
|
||||||
|
azure_client_id = '...'
|
||||||
|
azure_secret = '...'
|
||||||
|
|
||||||
|
# Corso passphrase
|
||||||
|
passphrase = '...'
|
||||||
|
```
|
||||||
|
|
||||||
</TabItem>
|
</TabItem>
|
||||||
<TabItem value="docker" label="Docker">
|
<TabItem value="docker" label="Docker">
|
||||||
|
|
||||||
@ -124,6 +167,24 @@ directory within the container.
|
|||||||
<command> <command options>`
|
<command> <command options>`
|
||||||
}</CodeBlock>
|
}</CodeBlock>
|
||||||
|
|
||||||
|
The config file can also be used to provide other configuration information like Azure and AWS credentials as mentioned below:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# AWS configs
|
||||||
|
aws_access_key_id = '...'
|
||||||
|
aws_secret_access_key = '...'
|
||||||
|
aws_session_token = '...'
|
||||||
|
|
||||||
|
# M365 config
|
||||||
|
account_provider = '...'
|
||||||
|
azure_tenantid = '...'
|
||||||
|
azure_client_id = '...'
|
||||||
|
azure_secret = '...'
|
||||||
|
|
||||||
|
# Corso passphrase
|
||||||
|
passphrase = '...'
|
||||||
|
```
|
||||||
|
|
||||||
</TabItem>
|
</TabItem>
|
||||||
</Tabs>
|
</Tabs>
|
||||||
|
|
||||||
|
|||||||
@ -85,8 +85,8 @@ Copy the client and tenant IDs and export them into the following environment va
|
|||||||
<TabItem value="win" label="Powershell">
|
<TabItem value="win" label="Powershell">
|
||||||
|
|
||||||
```powershell
|
```powershell
|
||||||
$Env:AZURE_CLIENT_ID = "<Application (client) ID for configured app>"
|
$Env:AZURE_CLIENT_ID = '<Application (client) ID for configured app>'
|
||||||
$Env:AZURE_TENANT_ID = "<Directory (tenant) ID for configured app>"
|
$Env:AZURE_TENANT_ID = '<Directory (tenant) ID for configured app>'
|
||||||
```
|
```
|
||||||
|
|
||||||
</TabItem>
|
</TabItem>
|
||||||
@ -124,7 +124,7 @@ environment variable.
|
|||||||
<TabItem value="win" label="Powershell">
|
<TabItem value="win" label="Powershell">
|
||||||
|
|
||||||
```powershell
|
```powershell
|
||||||
$Env:AZURE_CLIENT_SECRET = "<Client secret value>"
|
$Env:AZURE_CLIENT_SECRET = '<Client secret value>'
|
||||||
```
|
```
|
||||||
|
|
||||||
</TabItem>
|
</TabItem>
|
||||||
|
|||||||
@ -83,7 +83,7 @@ Before first use, you need to initialize a Corso repository with `corso repo ini
|
|||||||
|
|
||||||
```powershell
|
```powershell
|
||||||
# Initialize the Corso Repository
|
# Initialize the Corso Repository
|
||||||
$Env:CORSO_PASSPHRASE = "CHANGE-ME-THIS-IS-INSECURE"
|
$Env:CORSO_PASSPHRASE = 'CHANGE-ME-THIS-IS-INSECURE'
|
||||||
.\corso repo init s3 --bucket corso-test
|
.\corso repo init s3 --bucket corso-test
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user