Sayon Bhattacharjee
07/19/2023, 8:07 PM'{\"type\":\"service_account\",\"project_id\":\"project\", \"private_key\":\"-----BEGIN PRIVATE KEY-----\nYXYXXY}'
2. added those variables to the docker-compose.yaml in the server and worker containers
3. when I set those and try to enter a secret (for example the twilio source), this error appears
a. Internal Server Error: com.google.gson.stream.MalformedJsonException: Use JsonReader.setLenient(true) to accept malformed JSON at line 1 column 3 path $.kapa.ai
07/19/2023, 8:07 PMkapa.ai
07/19/2023, 8:07 PMSayon Bhattacharjee
07/19/2023, 8:07 PM'{\"type\":\"service_account\",\"project_id\":\"project\", \"private_key\":\"-----BEGIN PRIVATE KEY-----\nYXYXXY}'
2. added those variables to the docker-compose.yaml in the server and worker containers
3. when I set those and try to enter a secret (for example the twilio source), this error appears
a. Internal Server Error: com.google.gson.stream.MalformedJsonException: Use JsonReader.setLenient(true) to accept malformed JSON at line 1 column 3 path $.Willi
10/25/2023, 12:05 PMWilli
10/25/2023, 12:27 PMexport SECRET_STORE_GCP_PROJECT_ID=my-project-id
export SECRET_STORE_GCP_CREDENTIALS=$(gcloud secrets versions access 1 --secret airbyte_runner_service_account_key)
Of course, the service account key needs the role roles/secretmanager.admin . Beware that Airbyte wants to store secrets in the global region. I did not find a way to limit it to EU etc. :(
1. add the following variables to docker-compose.yaml to the environment for the services server and `worker`:
- SECRET_STORE_GCP_PROJECT_ID=${SECRET_STORE_GCP_PROJECT_ID}
- SECRET_STORE_GCP_CREDENTIALS=${SECRET_STORE_GCP_CREDENTIALS}
2. the service account has to be WITHOUT the single quotes quotes shown in 1.c up. The newlines can be kept and the quotes should NOT be escaped. Thus, it has to look like this:
{
"type": "service_account",
"project_id": "my-project-id",
"private_key_id": "123abc",
"private_key": "-----BEGIN PRIVATE KEY-----\n123\n456\n=\n-----END PRIVATE KEY-----\n",
"client_email": "airbyte-runner@my-project-id.iam.gserviceaccount.com",
"client_id": "987",
"auth_uri": "<https://accounts.google.com/o/oauth2/auth>",
"token_uri": "<https://oauth2.googleapis.com/token>",
"auth_provider_x509_cert_url": "<https://www.googleapis.com/oauth2/v1/certs>",
"client_x509_cert_url": "<https://www.googleapis.com/robot/v1/metadata/x509/airbyte-runner%40my-project-id.iam.gserviceaccount.com>",
"universe_domain": "googleapis.com"
}
Possible error messages:
⢠if the variables SECRET_STORE_GCP_PROJECT_ID and SECRET_STORE_GCP_CREDENTIALS are NOT set then the error message upon creating a source or destination will be in Airbyte 0.50.31: Internal Server Error: no JSON input found
⢠if the variables SECRET_STORE_GCP_PROJECT_ID and SECRET_STORE_GCP_CREDENTIALS are set, but the json secret is malformatted the error will be as described above Internal Server Error: com.google.gson.stream.MalformedJsonException: Use JsonReader.setLenient(true) to accept malformed JSON at line 1 column 3 path $.Kevin Lefevre
11/07/2023, 1:28 PMSECRET_STORE_GCP_CREDENTIALS in the .env natively used by the docker compose otherwise the command string $(gcloud secrets versions access 1 --secret airbyte_runner_service_account_key) would be passed to the container instead of the evaluation of the command šWilli
11/07/2023, 1:33 PMexport statements need to reside in a separate script. Thanks for highlighting this!