# # Copyright 2025 The Sigstore Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. services: spanner: image: gcr.io/cloud-spanner-emulator/emulator:1.5.42@sha256:335f6daa572494373ab0e16f6f574aced7425f3755182faf42089f838d6f38e1 gcs: image: fsouza/fake-gcs-server:1.52.3@sha256:666f86b873120818b10a5e68d99401422fcf8b00c1f27fe89599c35236f48b4c volumes: - bucket:/data/tiles:rw command: - "-scheme=http" - "-port=7080" - "-public-host=localhost:7080" ports: - "7080:7080" rekor_init: build: context: . dockerfile: Dockerfile.emulator_init environment: - GCP_PROJECT=rekor-tiles-e2e - SPANNER_INSTANCE=rekor-tiles - SPANNER_DB=sequencer - SPANNER_EMULATOR_REST_HOST=http://spanner:9020/ - SPANNER_EMULATOR_HOST=spanner:9010 healthcheck: test: - CMD-SHELL - "test -f /root/finished" timeout: 10s retries: 4 depends_on: - spanner - gcs rekor: build: context: . target: deploy environment: - SPANNER_EMULATOR_HOST=spanner:9010 - STORAGE_EMULATOR_HOST=gcs:7080 command: - "rekor-server" - "serve" - "--http-address=0.0.0.0" - "--grpc-address=0.0.0.0" - "--hostname=rekor-local" - "--gcp-bucket=tiles" - "--gcp-spanner=projects/rekor-tiles-e2e/instances/rekor-tiles/databases/sequencer" - "--signer-filepath=/pki/ed25519-priv-key.pem" - "--checkpoint-interval=2s" - "--log-level=debug" - "--request-response-logging=true" - "--persistent-antispam" ports: - "3003:3000" # http port - "3001:3001" # grpc port - "2114:2112" # metrics port healthcheck: test: - CMD-SHELL - curl http://localhost:3000/healthz | grep '{"status":"SERVING"}' timeout: 30s retries: 10 interval: 3s # requires docker engine >= v25 # start_period: 5s # start_interval: 1s volumes: - ./tests/testdata/pki:/pki depends_on: rekor_init: condition: service_completed_successfully # Launch with `docker compose up rekor-debug` # or `docker compose up rekor-debug --watch`. # This service runs with the dlv debugger already in the Dockerfile. # If using VSCode, add this debugger launch configuration # { # "version": "0.2.0", # "configurations": [ # { # "name": "Attach to Process", # "type": "go", # "request": "attach", # "mode": "remote", # "port": 2345 # }, # ] # } rekor-debug: profiles: - debug develop: watch: - path: ./ action: rebuild build: context: . target: debug environment: - SPANNER_EMULATOR_HOST=spanner:9010 - STORAGE_EMULATOR_HOST=gcs:7080 command: - "dlv" - "exec" - "--continue" # launch rekor-server without waiting for the dubbger client to connect. - "--accept-multiclient" - "--listen=:2345" - "--headless=true" - "--log=true" - "--api-version=2" - "--" - "/usr/local/bin/rekor-server" - "serve" - "--http-address=0.0.0.0" - "--grpc-address=0.0.0.0" - "--hostname=rekor-local" - "--gcp-bucket=tiles" - "--gcp-spanner=projects/rekor-tiles-e2e/instances/rekor-tiles/databases/sequencer" - "--signer-filepath=/pki/ed25519-priv-key.pem" - "--checkpoint-interval=2s" ports: - 2345:2345 - "3003:3000" # http port - "3001:3001" # grpc port - "2114:2112" # metrics port healthcheck: test: - CMD-SHELL - curl http://localhost:3000/healthz | grep '{"status":"SERVING"}' timeout: 30s retries: 10 interval: 3s # requires docker engine >= v25 # start_period: 5s # start_interval: 1s volumes: - ./tests/testdata/pki:/pki depends_on: rekor_init: condition: service_completed_successfully volumes: bucket: {}