Skip to content

Commit

Permalink
Use-reusable docker-compose
Browse files Browse the repository at this point in the history
  • Loading branch information
jlsherrill committed Dec 17, 2024
1 parent c0219b8 commit 8f66d31
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/tang-actions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ jobs:
- name: Wait for pulp
run: |
docker run --network=host --rm -v ${PWD}:/local curlimages/curl \
curl --retry-all-errors --fail --retry-delay 10 --retry 32 --retry-max-time 240 http://localhost:8080/api/pulp/default/api/v3/repositories/rpm/rpm/ -u admin:password
curl --retry-all-errors --fail --retry-delay 10 --retry 32 --retry-max-time 240 http://localhost:8087/api/pulp/default/api/v3/repositories/rpm/rpm/ -u admin:password
sleep 30
- name: integration tests
run: |
Expand All @@ -63,6 +63,6 @@ jobs:
DATABASE_USER: pulp
DATABASE_NAME: pulp
DATABASE_PASSWORD: password
SERVER_URL: http://localhost:8080
SERVER_URL: http://localhost:8087
SERVER_USERNAME: admin
SERVER_PASSWORD: password
8 changes: 4 additions & 4 deletions compose_files/pulp/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ services:
postgres:
image: "docker.io/library/postgres:16"
ports:
- "5434:5432"
- "${PULP_DATABASE_PORT:-5432}:5432"
environment:
POSTGRES_USER: pulp
POSTGRES_PASSWORD: password
Expand Down Expand Up @@ -64,7 +64,7 @@ services:
migration_service:
condition: service_completed_successfully
ports:
- 8080:24817
- ${PULP_API_PORT:-8080}:24817
hostname: pulp-api
user: pulp
volumes:
Expand All @@ -91,7 +91,7 @@ services:
migration_service:
condition: service_completed_successfully
ports:
- 8081:24816
- ${PULP_CONTENT_PORT:-8081}:24816
hostname: pulp-content
user: pulp
volumes:
Expand All @@ -111,7 +111,7 @@ services:
image: "quay.io/redhat-services-prod/pulp-services-tenant/pulp:latest"
platform: linux/amd64
deploy:
replicas: 1
replicas: "#{PULP_WORKER_COUNT:-2}"
command: ["pulp-worker"]
depends_on:
migration_service:
Expand Down
4 changes: 2 additions & 2 deletions mk/compose.mk
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@

.PHONY: compose-up
compose-up: ## Start up service dependencies using podman(docker)-compose
$(PULP_COMPOSE_COMMAND)
PULP_DATABASE_PORT=5434 PULP_API_PORT=8087 PULP_CONTENT_PORT=8088 $(PULP_COMPOSE_COMMAND)

.PHONY: compose-down
compose-down: ## Shut down service dependencies using podman(docker)-compose
$(PULP_COMPOSE_DOWN_COMMAND)

.PHONY: compose-clean ## Clear out data (dbs, files) for service dependencies
compose-clean: compose-down
$(DOCKER) volume prune --force
$(DOCKER) volume prune --force

0 comments on commit 8f66d31

Please sign in to comment.