feat: update Docker build to support amd64 and arm64, use --push
This commit is contained in:
4
Makefile
4
Makefile
@@ -71,10 +71,10 @@ test-watch: ## Run unit tests in watch mode
|
|||||||
|
|
||||||
docker-build: ## Build Docker image for local development
|
docker-build: ## Build Docker image for local development
|
||||||
@echo "Building Docker image for $(APP_NAME): $(DOCKER_IMAGE)"
|
@echo "Building Docker image for $(APP_NAME): $(DOCKER_IMAGE)"
|
||||||
@docker buildx build --platform linux/amd64 \
|
@docker buildx build --platform linux/amd64,linux/arm64 \
|
||||||
--build-arg NODE_ENV=production \
|
--build-arg NODE_ENV=production \
|
||||||
--build-arg APP_NAME=$(APP_NAME) \
|
--build-arg APP_NAME=$(APP_NAME) \
|
||||||
-t $(DOCKER_IMAGE) --load .
|
-t $(DOCKER_IMAGE) --push .
|
||||||
|
|
||||||
docker-run: ## Build and run Docker container
|
docker-run: ## Build and run Docker container
|
||||||
@echo "Building and running $(APP_NAME) container: $(DOCKER_IMAGE)"
|
@echo "Building and running $(APP_NAME) container: $(DOCKER_IMAGE)"
|
||||||
|
|||||||
Reference in New Issue
Block a user