Skip to content

Commit

Permalink
Working e2e
Browse files Browse the repository at this point in the history
Signed-off-by: nathannaveen <42319948+nathannaveen@users.noreply.github.com>
  • Loading branch information
nathannaveen committed Jul 2, 2024
1 parent 85e8c68 commit 812b76b
Show file tree
Hide file tree
Showing 3 changed files with 148 additions and 193 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -150,14 +150,15 @@ jobs:
- uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d
with:
python-version: '3.10'
- name: Print Bash version
run: bash --version
- name: Install dependencies
run: |
go mod download
pip install gql[all]
- name: Set up JetStream
uses: nats-io/jetstream-gh-action@v1
with:
nats_version: '2.9.17'
- name: Set up NATS Server with JetStream
run: |
docker run -d --name nats-server -p 4222:4222 -p 8222:8222 nats:2.9.17 -js
- name: Wait for PostgreSQL to be ready
run: |
until pg_isready -h localhost -p 5432 -U guac -d guac; do
Expand Down
206 changes: 96 additions & 110 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,120 +25,106 @@ services:
timeout: 10s
retries: 3
start_period: 5s
postgres:
image: docker.io/library/postgres:16

guac-collectsub:
networks: [ frontend ]
image: $GUAC_IMAGE
command: "/opt/guac/guaccsub"
working_dir: /guac
restart: on-failure
ports:
- "2782:2782"
depends_on:
nats:
condition: service_healthy
volumes:
- ./container_files/guac:/guac:z
healthcheck:
test: [ "CMD", "wget", "--spider", "http://localhost:2782" ]
interval: 10s
timeout: 10s
retries: 3
start_period: 5s

guac-ingestor:
networks: [ frontend ]
image: $GUAC_IMAGE
command: "/opt/guac/guacingest"
working_dir: /guac
restart: on-failure
depends_on:
guac-collectsub:
condition: service_healthy
volumes:
- ./container_files/guac:/guac:z
- blobstore:/tmp/blobstore

oci-collector:
networks: [ frontend ]
image: $GUAC_IMAGE
command: "/opt/guac/guaccollect image"
working_dir: /guac
restart: on-failure
depends_on:
guac-collectsub:
condition: service_healthy
volumes:
- ./container_files/guac:/guac:z
- blobstore:/tmp/blobstore

depsdev-collector:
networks: [ frontend ]
image: $GUAC_IMAGE
command: "/opt/guac/guaccollect deps_dev"
working_dir: /guac
restart: on-failure
environment:
POSTGRES_USER: guac
POSTGRES_PASSWORD: guac
- DEPS_DEV_APIKEY
depends_on:
guac-collectsub:
condition: service_healthy
volumes:
- ./container_files/guac:/guac:z
- blobstore:/tmp/blobstore
ports:
- "9091:9091" # for prometheus metrics

osv-certifier:
networks: [ frontend ]
image: $GUAC_IMAGE
command: "/opt/guac/guacone certifier osv"
working_dir: /guac
restart: on-failure
depends_on:
guac-collectsub:
condition: service_healthy
volumes:
- ./container_files/guac:/guac:z
guac-rest:
networks: [ frontend ]
image: $GUAC_IMAGE
command: "/opt/guac/guacrest"
working_dir: /guac
restart: on-failure
ports:
- "8081:8081"
volumes:
- ./postgres-data:/var/lib/postgresql/data:z
- ./container_files/guac:/guac:z
depends_on:
guac-graphql:
condition: service_healthy
healthcheck:
test: [ "CMD", "pg_isready", "--username=guac", "--dbname=guac" ]
test:
[
"CMD",
"wget",
"--spider",
"http://localhost:8081/healthz"
]
interval: 10s
timeout: 5s
retries: 5
start_period: 10s
#
# guac-collectsub:
# networks: [ frontend ]
# image: $GUAC_IMAGE
# command: "/opt/guac/guaccsub"
# working_dir: /guac
# restart: on-failure
# ports:
# - "2782:2782"
# depends_on:
# nats:
# condition: service_healthy
# volumes:
# - ./container_files/guac:/guac:z
# healthcheck:
# test: [ "CMD", "wget", "--spider", "http://localhost:2782" ]
# interval: 10s
# timeout: 10s
# retries: 3
# start_period: 5s
#
# guac-ingestor:
# networks: [ frontend ]
# image: $GUAC_IMAGE
# command: "/opt/guac/guacingest"
# working_dir: /guac
# restart: on-failure
# depends_on:
# guac-collectsub:
# condition: service_healthy
# volumes:
# - ./container_files/guac:/guac:z
# - blobstore:/tmp/blobstore
#
# oci-collector:
# networks: [ frontend ]
# image: $GUAC_IMAGE
# command: "/opt/guac/guaccollect image"
# working_dir: /guac
# restart: on-failure
# depends_on:
# guac-collectsub:
# condition: service_healthy
# volumes:
# - ./container_files/guac:/guac:z
# - blobstore:/tmp/blobstore
#
# depsdev-collector:
# networks: [ frontend ]
# image: $GUAC_IMAGE
# command: "/opt/guac/guaccollect deps_dev"
# working_dir: /guac
# restart: on-failure
# environment:
# - DEPS_DEV_APIKEY
# depends_on:
# guac-collectsub:
# condition: service_healthy
# volumes:
# - ./container_files/guac:/guac:z
# - blobstore:/tmp/blobstore
# ports:
# - "9091:9091" # for prometheus metrics
#
# osv-certifier:
# networks: [ frontend ]
# image: $GUAC_IMAGE
# command: "/opt/guac/guacone certifier osv"
# working_dir: /guac
# restart: on-failure
# depends_on:
# guac-collectsub:
# condition: service_healthy
# volumes:
# - ./container_files/guac:/guac:z
#
# guac-rest:
# networks: [ frontend ]
# image: $GUAC_IMAGE
# command: "/opt/guac/guacrest"
# working_dir: /guac
# restart: on-failure
# ports:
# - "8081:8081"
# volumes:
# - ./container_files/guac:/guac:z
# depends_on:
# guac-graphql:
# condition: service_healthy
# healthcheck:
# test:
# [
# "CMD",
# "wget",
# "--spider",
# "http://localhost:8081/healthz"
# ]
# interval: 10s
# timeout: 10s
# retries: 3
# start_period: 5s
timeout: 10s
retries: 3
start_period: 5s


networks:
Expand Down
Loading

0 comments on commit 812b76b

Please sign in to comment.