Skip to content

Configuration

This page shows where Aider's files live on the instance, how to give Aider your provider key safely, and how to work on your own repositories.

Where things live

Path What it is
/usr/local/bin/aider The aider command. It runs Aider from /opt/aider/venv.
/etc/aider/aider.conf.yml The image's default Aider settings, written on first boot.
/etc/aider/secrets An empty place for credentials, root:aider, mode 0750. The ubuntu user cannot read it.
/var/lib/aider/workspace The sample git repository, owned by ubuntu.
/opt/sushi/docs/README.md The image notes.
/usr/share/doc/aider Aider's license and source archives.

First boot creates /etc/aider/aider.conf.yml only if it does not exist yet, so your edits are kept across reboots.

The default settings

/etc/aider/aider.conf.yml contains no keys. Its defaults are:

analytics: false
check-update: false
gitignore: true
auto-commits: false
pretty: true
  • analytics: false and check-update: false keep Aider from sending usage data or checking for new versions.
  • auto-commits: false leaves committing to you. Set it to true if you want Aider to commit each change it makes.

Aider reads this file when you pass it with --config:

aider --config /etc/aider/aider.conf.yml

To change the defaults, edit the file with sudo:

sudo nano /etc/aider/aider.conf.yml

Provider keys

The image contains no provider keys. Aider picks up the key for your provider from environment variables, such as OPENAI_API_KEY or ANTHROPIC_API_KEY. Choose one of these:

  • Per session. Export the key in a private shell, as in Getting started. It is gone when you log out.
  • An env file. Create a file that only you can read, then point Aider at it with --env-file:

    install -m 0600 /dev/null ~/.aider-keys.env
    nano ~/.aider-keys.env
    
    aider --config /etc/aider/aider.conf.yml --env-file ~/.aider-keys.env --model <model-name>
    

Never put keys in EC2 user data, in the AMI, or in a file other users can read.

Use Amazon Bedrock

Aider can call Amazon Bedrock models with the instance role instead of a key. Add a policy to the instance role that allows the Bedrock model you want, make sure the model is enabled in your account, then pass the region and a bedrock/ model name:

AWS_REGION=<region> aider --config /etc/aider/aider.conf.yml --model bedrock/<model-id>

Bedrock usage is billed by AWS separately.

Work on your own repositories

Aider works inside any git repository. Clone your project as the ubuntu user and start Aider from its directory:

cd ~
git clone <repository-url>
cd <repository>
aider --config /etc/aider/aider.conf.yml --model <model-name>

To push changes back, set up access to your git host, for example with a deploy key or a token you keep on the instance only.

Aider keeps its chat history in .aider* files inside each repository. With gitignore: true, Aider adds them to the repository's .gitignore.

Last updated October 13, 2026 · Suggest an improvement