Skip to content

Commit 5dbc026

Browse files
committed
reflect changes to deployment scripts
1 parent e65204f commit 5dbc026

File tree

2 files changed

+18
-9
lines changed

2 files changed

+18
-9
lines changed

Makefile

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,8 @@ frontend: ## run frontend
116116
# ---
117117
.PHONY: azure-functions-start
118118
azure-functions-start: ## start Azure Functions
119-
poetry run func start
119+
cd backend \
120+
&& poetry run func start
120121

121122
.PHONY: azure-functions-deploy
122123
azure-functions-deploy: ## deploy Azure Functions resources
@@ -126,14 +127,9 @@ azure-functions-deploy: ## deploy Azure Functions resources
126127
azure-functions-destroy: ## destroy Azure Functions resources
127128
sh ./scripts/destroy-azure-functions.sh
128129

129-
.PHONY: azure-functions-functionapp-deploy
130-
azure-functions-functionapp-deploy: ## deploy Azure Functions App
131-
poetry export \
132-
--format requirements.txt \
133-
--output requirements.txt \
134-
--with backend,azure-functions \
135-
--without-hashes
136-
func azure functionapp publish $(shell jq -r '.FUNCTION_APP_NAME' < azure-functions.json)
130+
.PHONY: azure-functions-publish
131+
azure-functions-publish: ## publish Azure Functions App
132+
sh ./scripts/publish-azure-functions.sh
137133

138134
# ---
139135
# OpenAPI Client

scripts/publish-azure-functions.sh

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
#!/bin/sh
2+
3+
# Export the dependencies to requirements.txt
4+
poetry export \
5+
--format requirements.txt \
6+
--output backend/requirements.txt \
7+
--with backend,azure-functions \
8+
--without-hashes
9+
10+
# Publish the Azure Functions
11+
cd backend || exit
12+
FUNCTION_APP_NAME=$(jq -r '.FUNCTION_APP_NAME' < ../azure-functions.json)
13+
func azure functionapp publish $FUNCTION_APP_NAME

0 commit comments

Comments
 (0)