Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(docker_compose): remove obsolete "version" parameter #60

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

gclough
Copy link

@gclough gclough commented Jan 2, 2025

When running docker-compose it warns that this parameter is now ignored, so it should be removed:

% docker-compose build && docker-compose run dev

WARN[0000] /Users/gclough/Documents/GitHub/prometheus-pgbouncer-exporter/docker-compose.yml: the attribute `version` is obsolete, it will be ignored, please remove it to avoid potential confusion 
[+] Building 0/0
[+] Building 0/1Building                                                                                                                                                                                                                                                                                                                                    0.1s 
[+] Building 12.4s (11/11) FINISHED                                                                                                                                                                                                                                                                                                         docker:desktop-linux 
...

@gclough
Copy link
Author

gclough commented Jan 2, 2025

Tests work:

% docker-compose build && docker-compose run dev

[+] Building 0/0
[+] Building 0/1Building                                                                                                                                                                                                                                                                                                                                    0.1s 
[+] Building 0.8s (11/11) FINISHED                                                                                                                                                                                                                                                                                                          docker:desktop-linux 
 => [dev internal] load build definition from Dockerfile-dev                                                                                                                                                                                                                                                                                                0.0s
 => => transferring dockerfile: 330B                                                                                                                                                                                                                                                                                                                        0.0s
 => [dev internal] load metadata for docker.io/library/python:3.6-alpine                                                                                                                                                                                                                                                                                    0.7s 
 => [dev internal] load .dockerignore                                                                                                                                                                                                                                                                                                                       0.0s
 => => transferring context: 2B                                                                                                                                                                                                                                                                                                                             0.0s
 => [dev internal] load build context                                                                                                                                                                                                                                                                                                                       0.0s
 => => transferring context: 6.35kB                                                                                                                                                                                                                                                                                                                         0.0s
 => [dev 1/5] FROM docker.io/library/python:3.6-alpine@sha256:579978dec4602646fe1262f02b96371779bfb0294e92c91392707fa999c0c989                                                                                                                                                                                                                              0.0s
 => CACHED [dev 2/5] COPY . /prometheus-pgbouncer-exporter                                                                                                                                                                                                                                                                                                  0.0s
 => CACHED [dev 3/5] RUN  apk add --update --no-cache postgresql-dev gcc musl-dev &&      pip install -r /prometheus-pgbouncer-exporter/requirements.txt                                                                                                                                                                                                    0.0s
 => CACHED [dev 4/5] WORKDIR /prometheus-pgbouncer-exporter                                                                                                                                                                                                                                                                                                 0.0s
 => CACHED [dev 5/5] RUN python setup.py install                                                                                                                                                                                                                                                                                                            0.0s
 => [dev] exporting to image                                                                                                                                                                                                                                                                                                                                0.0s
 => => exporting layers                                                                                                                                                                                                                                                                                                                                     0.0s
 => => writing image sha256:b83758c4154408d5dad9a7f5f6a0c85b79f16b0c6086f23255e43e78d736158e                                                                                                                                                                                                                                                                0.0s
[+] Building 1/1 docker.io/library/prometheus-pgbouncer-exporter-dev                                                                                                                                                                                                                                                                                        0.0s
 ✔ Service dev  Built                                                                                                                                                                                                                                                                                                                                       0.9s 
WARN[0000] Found orphan containers ([prometheus-pgbouncer-exporter-dev-run-23a68608987a prometheus-pgbouncer-exporter-dev-run-cd9d58322a6b]) for this project. If you removed or renamed this service in your compose file, you can run this command with the --remove-orphans flag to clean it up. 
/prometheus-pgbouncer-exporter # 
/prometheus-pgbouncer-exporter # python -m unittest
................................
----------------------------------------------------------------------
Ran 32 tests in 8.055s

OK

@gclough gclough marked this pull request as ready for review January 2, 2025 16:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant