Skip to content

Commit

Permalink
Fix up a few issues:
Browse files Browse the repository at this point in the history
- correctly reference hosted_ca.pem
- ignore creds_hosted.env
- introduce development/docker-compose.base-hosted.yml, which doesn't depend on db, since we're not running db when using hosted dolt
  • Loading branch information
PavelSafronov committed May 15, 2023
1 parent 739b019 commit 7f348c5
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 3 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -309,4 +309,5 @@ public

# Custom
hosted_ca.pem
.idea
.idea
creds_hosted.env
37 changes: 37 additions & 0 deletions development/docker-compose.base-hosted.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
x-nautobot-build: &nautobot-build
build:
args:
NAUTOBOT_VER: "${NAUTOBOT_VER}"
PYTHON_VER: "${PYTHON_VER}"
context: "../"
dockerfile: "development/Dockerfile"
x-nautobot-base: &nautobot-base
image: "nautobot-version-control/nautobot:${NAUTOBOT_VER}-py${PYTHON_VER}"
env_file:
- "development.env"
- "creds.env"
tty: true

version: "3.8"
services:
nautobot:
depends_on:
redis:
condition: "service_started"
<<: *nautobot-build
<<: *nautobot-base
worker:
entrypoint:
- "sh"
- "-c" # this is to evaluate the $NAUTOBOT_LOG_LEVEL from the env
- "nautobot-server celery worker -l $$NAUTOBOT_LOG_LEVEL --events" ## $$ because of docker-compose
depends_on:
- "nautobot"
healthcheck:
interval: "30s"
timeout: "10s"
start_period: "30s"
retries: 3
test: ["CMD", "bash", "-c", "nautobot-server celery inspect ping --destination celery@$$HOSTNAME"] ## $$ because of docker-compose
<<: *nautobot-base
4 changes: 2 additions & 2 deletions development/docker-compose.dolt-hosted.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ services:
volumes:
- "./nautobot_config.py:/opt/nautobot/nautobot_config.py"
- "../:/source"
- "development/hosted_ca.pem:/opt/nautobot/hosted_ca.pem"
- "./hosted_ca.pem:/opt/nautobot/hosted_ca.pem"
worker:
depends_on:
redis:
Expand All @@ -25,4 +25,4 @@ services:
volumes:
- "./nautobot_config.py:/opt/nautobot/nautobot_config.py"
- "../:/source"
- "development/hosted_ca.pem:/opt/nautobot/hosted_ca.pem"
- "./hosted_ca.pem:/opt/nautobot/hosted_ca.pem"

0 comments on commit 7f348c5

Please sign in to comment.