Skip to content

Commit

Permalink
refactor(container): move app root out of /home
Browse files Browse the repository at this point in the history
removed explicit WORKDIR in appcontainer as the base image already
sets the default we want
  • Loading branch information
thekaveman committed Jul 9, 2024
1 parent b32d4de commit a1f5b78
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"dockerComposeFile": ["../compose.yml"],
"service": "dev",
"runServices": ["dev", "docs"],
"workspaceFolder": "/home/calitp/app",
"workspaceFolder": "/calitp/app",
"postAttachCommand": ["/bin/bash", ".devcontainer/postAttach.sh"],
"postStartCommand": ["/bin/bash", "bin/init.sh"],
"customizations": {
Expand Down
2 changes: 0 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ RUN pip install build && python -m build

FROM ghcr.io/cal-itp/docker-python-web:main as appcontainer

WORKDIR /home/calitp/app

# upgrade pip
RUN python -m pip install --upgrade pip

Expand Down
6 changes: 3 additions & 3 deletions compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ services:
ports:
- "8000"
volumes:
- .:/home/calitp/app/
- ./:/calitp/app/

dev:
build:
Expand All @@ -20,7 +20,7 @@ services:
ports:
- "8000"
volumes:
- .:/home/calitp/app/
- ./:/calitp/app/

docs:
image: eligibility_server:dev
Expand All @@ -29,4 +29,4 @@ services:
ports:
- "8001"
volumes:
- .:/home/calitp/app
- ./:/calitp/app
2 changes: 1 addition & 1 deletion terraform/app_service.tf
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ resource "azurerm_service_plan" "main" {
}

locals {
mount_path = "/home/calitp/app/config"
mount_path = "/calitp/app/config"
}

resource "azurerm_linux_web_app" "main" {
Expand Down

0 comments on commit a1f5b78

Please sign in to comment.