On a new self-managed community edition installati...
# ask-ai
i
On a new self-managed community edition installation (1.8) in AWS EKS and trying to debug some issues. When trying to set up both sources and destinations, every one gives "An unexpected error occurred. Please report this if the issue persists. (HTTP 500)" when trying to save. I can see Airbyte successfully log into the endpoints with the given credentials, but it fails at some point during the process. What might cause every connection save to fail with this 500 error?
k
Based on the knowledge sources, there are several potential causes for persistent HTTP 500 errors when saving sources and destinations in a self-managed Airbyte Community Edition installation on AWS EKS: 1. Missing or Misconfigured Environment Variables (AWS Credentials): - In Airbyte deployments on Kubernetes/EKS, especially when using AWS services (like S3 or Secrets Manager), the spawned pods (such as those for source/destination checks) require AWS credentials (
AWS_ACCESS_KEY_ID
and
AWS_SECRET_ACCESS_KEY
) to be present in their environment. If these are missing or not properly propagated to all containers (init, main, and sidecar), the pods may fail, resulting in HTTP 500 errors during connector setup. This has been specifically observed in Airbyte 1.2.0 and similar issues may persist in later versions if the configuration is not correct. Ensuring these environment variables are set in your Helm
values.yaml
and are available to all relevant containers is critical. See the following for a working example:
Copy code
yaml    workload-launcher:      env_vars:        AWS_ASSUME_ROLE_SECRET_NAME: airbyte-config-secrets        AWS_SECRET_MANAGER_ACCESS_KEY_ID_REF_NAME: airbyte-config-secrets        AWS_SECRET_MANAGER_ACCESS_KEY_ID_REF_KEY: aws-secret-manager-access-key-id        AWS_SECRET_MANAGER_SECRET_ACCESS_KEY_REF_NAME: airbyte-config-secrets        AWS_SECRET_MANAGER_SECRET_ACCESS_KEY_REF_KEY: aws-secret-manager-secret-access-key
This configuration solved similar 500 errors for other users on EKS deployments. Double-check that your credentials are correctly set and accessible to all Airbyte pods involved in connector setup and testing. [See details](https://github.com/airbytehq/airbyte/issues/48809) 2. Pod Initialization Failures: - If the init or main containers in the connector check pods fail to start or complete successfully (often due to missing environment variables or misconfiguration), the workload launcher will report an internal server error (HTTP 500) to the UI. Logs may show errors like
Init container for Pod: pods did not complete successfully. Actual termination reason: Error
or AWS credential loading failures. [See details](https://github.com/airbytehq/airbyte/issues/48809) 3. Secret Management Issues: - If you are using AWS Secrets Manager or another secret backend, ensure that Airbyte is able to access and read the required secrets. Errors such as
Unable to load AWS credentials from any provider in the chain
indicate that the secret management configuration is incomplete or incorrect. [See details](https://github.com/airbytehq/airbyte/issues/48809) 4. General Misconfiguration or Missing Services: - In some cases, users have reported that only one Airbyte container was running, which may indicate that not all required services are up. Ensure that all Airbyte components (server, worker, etc.) are running and healthy. [See details](https://github.com/airbytehq/airbyte/issues/66692) Recommended Actions: - Review your Helm
values.yaml
and ensure all required AWS credentials and environment variables are set and correctly referenced. - Check the logs of the failing pods (especially the init and main containers) for credential or secret access errors. - Make sure all Airbyte services are running and healthy in your Kubernetes cluster. - If using secret managers, verify that Airbyte has the necessary permissions and configuration to access secrets. If after these checks the issue persists, provide pod logs and your Helm configuration for further debugging. --- If you need more specific troubleshooting, please provide relevant pod logs or error messages from the Airbyte UI or Kubernetes events.
i
@kapa.ai it seems like Airbyte is attempting to assume the wrong role--it is choosing a role that doesn't have correct s3 permissions and it is of course failing. How do I force airbyte on AWS EKS to choose a specific role to assume when running aws operations
k
A message from kapa.ai
To force Airbyte on AWS EKS to use a specific IAM role for AWS operations (such as accessing S3), you should configure your Kubernetes service account with the correct IAM role using IRSA (IAM Roles for Service Accounts). Here’s how you can ensure Airbyte uses the intended role: 1. Create an IAM Role with the Required Policies Attach the necessary S3 permissions to the IAM role. Example policy:
Copy code
json    {      "Version": "2012-10-17",      "Statement": [        { "Effect": "Allow", "Action": "s3:ListAllMyBuckets", "Resource": "*" },        {          "Effect": "Allow",          "Action": ["s3:ListBucket", "s3:GetBucketLocation"],          "Resource": "arn:aws:s3:::YOUR-S3-BUCKET-NAME"        },        {          "Effect": "Allow",          "Action": [            "s3:PutObject",            "s3:PutObjectAcl",            "s3:GetObject",            "s3:GetObjectAcl",            "s3:DeleteObject"          ],          "Resource": "arn:aws:s3:::YOUR-S3-BUCKET-NAME/*"        }      ]    }
[See AWS S3 Policy Example](https://docs.airbyte.com/platform/1.7/enterprise-setup/implementation-guide#aws-policies-appendix) 2. Annotate the Kubernetes Service Account Annotate the service account used by Airbyte with the IAM role ARN:
Copy code
yaml    apiVersion: v1    kind: ServiceAccount    metadata:      name: airbyte-admin      annotations:        eks.amazonaws.com/role-arn: arn:aws:iam::<account_id>:role/<Airbyte-role>
In your Helm values, you can specify:
Copy code
yaml    global:      serviceAccountName: airbyte-admin    serviceAccount:      annotations:        eks.amazonaws.com/role-arn: "arn:aws:iam::<account_id>:role/<Airbyte-role>"
[See user example and discussion](https://github.com/airbytehq/airbyte/issues/53652) 3. Ensure Airbyte Pods Use the Correct Service Account Make sure that all Airbyte workload pods (including those for source/destination connectors) are launched with this service account. If pods are using the default service account, they may fall back to the node IAM role, which often lacks the necessary permissions. [See related troubleshooting](https://github.com/airbytehq/airbyte/issues/50979) 4. Set Authentication Type to Instance Profile In your Helm values, set the authentication type to
instanceProfile
to ensure Airbyte uses the service account’s IAM role:
Copy code
yaml    global:      storage:        type: S3        s3:          region: <your-region>          authenticationType: instanceProfile
[See working configuration](https://github.com/airbytehq/airbyte/issues/53652) Summary: By annotating the correct Kubernetes service account with the desired IAM role and ensuring all Airbyte pods use this service account, you can control which role Airbyte assumes for AWS operations. Double-check your Helm values and pod specs to confirm the correct service account is always used. If you still see Airbyte falling back to the node role, verify that your pod specs and Helm values are not defaulting to the
default
service account.