You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gpt4free/docs/docker.md

1.1 KiB

G4F - Docker

If you have Docker installed, you can easily set up and run the project without manually installing dependencies.

  1. First, ensure you have both Docker and Docker Compose installed.

  2. Clone the GitHub repo:

git clone https://github.com/xtekky/gpt4free.git
  1. Navigate to the project directory:
cd gpt4free
  1. Build the Docker image:
docker pull selenium/node-chrome
docker-compose build
  1. Start the service using Docker Compose:
docker-compose up

Your server will now be running at http://localhost:1337. You can interact with the API or run your tests as you would normally.

To stop the Docker containers, simply run:

docker-compose down

[!Note] When using Docker, any changes you make to your local files will be reflected in the Docker container thanks to the volume mapping in the docker-compose.yml file. If you add or remove dependencies, however, you'll need to rebuild the Docker image using docker-compose build.

Return to Home