{"id":19260908,"url":"https://github.com/evant/docker-compose-test","last_synced_at":"2025-07-16T03:46:36.278Z","repository":{"id":144875456,"uuid":"347548278","full_name":"evant/docker-compose-test","owner":"evant","description":"A helper to run integration tests with docker-compose","archived":false,"fork":false,"pushed_at":"2021-03-14T17:34:39.000Z","size":13,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-02-23T18:32:19.381Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/evant.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-03-14T05:01:33.000Z","updated_at":"2021-03-15T14:28:39.000Z","dependencies_parsed_at":null,"dependency_job_id":"eb4ffb15-f71e-48e2-a844-33acd0fa2a24","html_url":"https://github.com/evant/docker-compose-test","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/evant/docker-compose-test","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evant%2Fdocker-compose-test","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evant%2Fdocker-compose-test/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evant%2Fdocker-compose-test/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evant%2Fdocker-compose-test/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/evant","download_url":"https://codeload.github.com/evant/docker-compose-test/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evant%2Fdocker-compose-test/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265479860,"owners_count":23773628,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-09T19:23:26.275Z","updated_at":"2025-07-16T03:46:36.046Z","avatar_url":"https://github.com/evant.png","language":"Rust","readme":"# docker-compose-test\n\nA helper to run integration tests with docker-compose.\n\n## Usage\n\nIn addition to your normal `docker-compose.yml`, create a `docker-compose.integration-tests.yml` to define\nyour services to run tests on. For example, say if you have the below setup:\n\n```yaml\n# docker-compose.yml\nservices:\n  postgres:\n    image: docker.io/postgres:13.1-alpine\n    ports:\n      - \"0.0.0.0:5432:5432\"\n    environment:\n      POSTGRES_PASSWORD: password\n  server:\n    build: server\n    command: npm run start\n    ports:\n      - \"0.0.0.0:3000:3000\"\n    volumes:\n      - \"./src:/app\" \n    depends_on:\n      - postgres\n```\n\nthen you'd define:\n\n```yaml\n# docker-compose.integration-tests.yml\nservices:\n  server:\n    command: npm test\n```\n\nThen you can run `docker-compose-test` and it'll spin up your database and run your tests!\n\nIf you have multiple services this will run all of them by default. You can also pass in the services you want run.\n\n```yaml\nservices:\n  server:\n    command: npm test\n  web:\n    command: npm test\n```\n\n`docker-compose-test web` will only run web.\n\n## Configuration\n\nIf you don't want to use the default file names, you can pass them explicitly. Note, it's expected that your test \nservice is the last file.\n\n`docker-compose-test -f container-compose.yml -f test-container-compose.yml`\n\nYou can override the default docker \u0026 docker-compose binaries by using the `$DOCKER` and `$DOCKER_COMPOSE` env variables\nrespectively.\n\n```shell\nexport DOCKER=podman\nexport DOCKER_COMPOSE=podman-compose\ndocker-compose-test\n```","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevant%2Fdocker-compose-test","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fevant%2Fdocker-compose-test","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevant%2Fdocker-compose-test/lists"}