-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathMakefile
More file actions
32 lines (26 loc) · 736 Bytes
/
Makefile
File metadata and controls
32 lines (26 loc) · 736 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
.PHONY: up down shell iex build
CONTAINER_NAME := ash-backpex-dev
IMAGE_NAME := ash-backpex-dev
# Build the image
build:
docker build -t $(IMAGE_NAME) .devcontainer/
# Start the devcontainer
up: build
docker run -d --name $(CONTAINER_NAME) \
-v $(PWD):/workspace \
-v $(HOME)/.claude:/home/vscode/.claude \
-v $(HOME)/.ssh:/home/vscode/.ssh:ro \
-p 4000:4000 \
-w /workspace \
$(IMAGE_NAME) sleep infinity
docker exec $(CONTAINER_NAME) mix deps.get
# Stop the devcontainer
down:
-docker stop $(CONTAINER_NAME)
-docker rm $(CONTAINER_NAME)
# Open a bash shell in the container
shell:
docker exec -it $(CONTAINER_NAME) bash
# Open an iex session in the container
iex:
docker exec -it $(CONTAINER_NAME) iex -S mix