CLI Cheatsheet
Quick reference for Java Azure Functions operational workflows.
Topic/Command Groups
flowchart TD
A[func commands] --> B[Local development]
C[az functionapp] --> D[Cloud operations]
E[mvn] --> F[Build and deploy]
| CLI element | Explanation |
| Command(s) | az functionapp] |
| Key flags | None |
| Variables | None |
| Expected result | Azure CLI completes successfully and returns JSON, table, or no output depending on the command; verify the next documented check before continuing. |
# Java project scaffolding uses Maven archetype, not func init --java
mvn archetype:generate -DarchetypeGroupId=com.microsoft.azure -DarchetypeArtifactId=azure-functions-archetype
func start
Maven
mvn clean package
mvn azure-functions:deploy -DfunctionAppName=$APP_NAME
Azure CLI
az functionapp create --name $APP_NAME --resource-group $RG --storage-account $STORAGE_NAME --plan $PLAN_NAME --runtime java --runtime-version 17 --functions-version 4 --os-type linux
az functionapp config appsettings list --name $APP_NAME --resource-group $RG --output table
az functionapp log tail --name $APP_NAME --resource-group $RG
| CLI element | Explanation |
| Command(s) | az functionapp create, az functionapp config appsettings list, az functionapp log tail |
| Key flags | --name, --resource-group, --storage-account, --plan, --runtime, --runtime-version, --functions-version, --os-type, --output |
| Variables | $APP_NAME, $RG, $STORAGE_NAME, $PLAN_NAME |
| Expected result | Azure CLI returns provisioning details; confirm the resource name and successful provisioning state before continuing. |
See Also
Sources