Commit graph

44 commits

Author SHA1 Message Date
Paul Gauthier
ea49cdeb17 feat: Add google-cloud-aiplatform dependency to Dockerfile 2025-03-05 16:59:41 -08:00
Paul Gauthier (aider)
d53ee24741 build: Add boto3 to Dockerfile pip install commands 2025-02-04 12:52:05 -08:00
Paul Gauthier
2f4490d059 fix: Update Dockerfile HOME env to persist container data in host filesystem 2025-02-04 07:51:00 -08:00
Paul Gauthier (aider)
81b7bd35f4 fix: Adjust permissions for directories to allow writing with -u switch 2025-02-03 18:53:16 -08:00
Paul Gauthier
4b946a23ca chore: Set HOME environment variable in Dockerfile 2025-02-03 18:53:15 -08:00
Paul Gauthier
18d1d7af33 no chown for COPY 2025-01-11 07:46:23 -08:00
Paul Gauthier (aider)
78ebb6295d fix: Restore site-packages permissions in Dockerfile for appuser access 2025-01-11 06:48:26 -08:00
Paul Gauthier (aider)
e1a3b77d67 feat: add rootless container support with dedicated appuser 2025-01-09 11:26:06 -08:00
Paul Gauthier
69b76c23e8 fix playwright install in both docker images 2024-08-19 15:02:53 -07:00
Paul Gauthier
14b26420b1 fix: Set is_update_available flag in versioncheck.py
build: Update AIDER_DOCKER_IMAGE environment variable in Dockerfile
2024-08-06 11:22:05 -03:00
Paul Gauthier (aider)
a369e0c281 feat: Add AIDER_DOCKER_IMAGE=true environment variable to aider-full and aider Docker images 2024-08-06 11:13:52 -03:00
Paul Gauthier
a01749cb32 fix: Add permissions to Python packages in Docker image 2024-08-06 11:13:51 -03:00
Paul Gauthier (aider)
dde7906cf1 fix: correct the {bin,...} in Dockerfile 2024-07-31 10:20:48 -03:00
Paul Gauthier
711ca9df08 feat(docker): add permissions kludges to support docker run --user xxx
The changes in this commit add some permission kludges to the Docker image to support running the container with the `--user` flag. Specifically, it:

- Adds permissions to the virtual environment directory and subdirectories to allow read/write/execute access for all users.
- Creates the `.aider` and `.cache` directories and grants read/write/execute access to all users.

This ensures that the container can be run with a non-root user without encountering permission issues.
2024-07-31 10:20:47 -03:00
Paul Gauthier (aider)
67c4df09fd feat: create virtual environment for aider installation
The changes in this commit create a virtual environment for the aider application in the Docker image. The key changes are:

1. Removes the permission-related commands that were modifying system directories.
2. Creates a virtual environment at `/venv` and adds it to the PATH.
3. Installs aider and its dependencies into the virtual environment.
4. Updates the ENTRYPOINT to use the aider executable from the virtual environment.
5. Copies the aider source to a temporary directory (`/tmp/aider`) for installation, then removes it after installation.

These changes should address the concerns about modifying system permissions while still allowing the container to function properly for different users.
2024-07-31 10:14:29 -03:00
Paul Gauthier
48e831d651 set perms on /.cache 2024-07-31 10:04:08 -03:00
Paul Gauthier
745c0fcfef feat(docker): add support for running as non-root user
The changes in this commit add support for running the Docker container as a non-root user. Specifically:

- Set permissions on the /.aider and /app directories to allow read/write/execute access for all users.
- Configure Git to consider the /app directory as a safe directory, which prevents Git from complaining about unusual permissions when running as a non-root user.
- Ensure that the Python site-packages directory and other relevant directories have read/write/execute permissions for all users, so that pip installs work even when running as a non-root user.

These changes will allow the Docker container to be run with the `--user` flag, which is a common requirement for running containers in production environments.
2024-07-31 09:52:53 -03:00
Paul Gauthier
adfde505d4 feat(docker): add directories and permissions for app and aider 2024-07-31 09:28:09 -03:00
Paul Gauthier
d1e385dea1 Added playwright to aider-full image 2024-07-30 20:44:17 -03:00
Paul Gauthier (aider)
4fded189f8 Build multi-stage Docker images for core "aider" and full "aider-full" versions 2024-07-30 17:11:12 -03:00
Paul Gauthier
b18dbf4772 renamed hf-embed -> help 2024-07-16 11:03:01 +01:00
Paul Gauthier
c1bb07269a restored build-essentials in docker image 2024-07-11 06:18:28 +01:00
Paul Gauthier
8b0e941c4d simpler docker build 2024-07-10 19:36:30 +01:00
Paul Gauthier
9e3eb4fce5 move llama core into hf-embed 2024-07-10 17:44:26 +01:00
Paul Gauthier
f688c18b65 offer to install aider[hf] 2024-07-10 16:20:06 +01:00
Paul Gauthier
cd2aca1d74 simplify multi stage dockerfile 2024-07-10 15:26:43 +01:00
Paul Gauthier (aider)
60ad0dee25 Implemented a multi-stage Dockerfile to reduce the final image size by removing build dependencies. 2024-07-09 18:06:54 +01:00
Paul Gauthier
e307be1a9c refactored into get_requirements 2024-07-09 16:39:54 +01:00
Paul Gauthier
c9aa36d7b6 Put build-essential back into dockerfile 2023-10-31 14:52:04 -07:00
Paul Gauthier
5280549c33 Upgrade to grep-ast 0.2.2 to streamline tree-sitter install 2023-10-31 11:28:34 -07:00
Paul Gauthier
7aa59c1331 added build-essential to dockerfile 2023-10-30 09:05:22 -07:00
Paul Gauthier
0030615578 removed universal-ctags from docker image 2023-10-29 13:10:31 -07:00
Paul Gauthier
b2b78a98ee Added libportaudio2 to the docker container 2023-10-18 13:38:41 -07:00
Paul Gauthier
49b9034629 Added universal ctags to the docker image 2023-10-18 13:30:49 -07:00
Paul Gauthier
790f7ddee3 make the docker image a bit smaller 2023-10-18 13:26:20 -07:00
Paul Gauthier
ee3f3a44fd aider: Refactored Dockerfile to combine RUN commands, use --no-cache-dir option when installing Python packages, and remove unnecessary pip install --upgrade pip command.
# Aider chat conversation:

ASSISTANT: Yes, there are a few more things we can do to clean up the Dockerfile:

1. We can combine the `RUN` commands into a single command to reduce the number of layers in the Docker image. This can make the image smaller and faster to build.

2. We can use the `--no-cache-dir` option when installing Python packages with pip. This will prevent pip from caching downloaded packages, which can save space in the Docker image.

3. We can remove the `pip install --upgrade pip` command. The Python Docker images are regularly updated, so the version of pip included in the image is usually fairly recent.

Here's how we can make these changes:

```dockerfile
docker/Dockerfile
<<<<<<< HEAD
FROM python:3.10-slim
RUN apt-get update && apt-get install -y git && rm -rf /var/lib/apt/lists/*
COPY . /aider
RUN pip install --upgrade pip && pip install /aider && rm -rf /aider
WORKDIR /app
ENTRYPOINT ["aider"]
=======
FROM python:3.10-slim
RUN apt-get update && apt-get install -y git && rm -rf /var/lib/apt/lists/* && \
    pip install --no-cache-dir /aider && rm -rf /aider
WORKDIR /app
ENTRYPOINT ["aider"]
>>>>>>> updated
```

Please note that these changes will make the Docker image smaller and faster to build, but they won't affect the functionality of the application.
2023-10-18 13:19:22 -07:00
Paul Gauthier
a6a49b13bb Remove the /aider directory after installing the package. 2023-10-18 13:19:21 -07:00
Paul Gauthier
4a10087a6e Moved docker docs into docs/ 2023-10-18 09:31:17 -07:00
Paul Gauthier
be201657b8 copy 2023-10-18 09:20:36 -07:00
Paul Gauthier
55d33efbfb copy 2023-10-18 09:18:43 -07:00
Paul Gauthier
fc92862017 enable pypi again 2023-10-18 09:15:40 -07:00
Paul Gauthier
b69edcfcba prep docker build to run in github action 2023-10-18 08:45:02 -07:00
Paul Gauthier
f954bc2ecc Changed RUN to ENTRYPOINT 2023-10-18 08:27:32 -07:00
Paul Gauthier
f068e49501 added experimental docker image 2023-10-18 08:25:17 -07:00