Azure / static-web-apps

Azure Static Web Apps. For bugs and feature requests, please create an issue in this repo. For community discussions, latest updates, kindly refer to the Discussions Tab. To know what's new in Static Web Apps, visit https://aka.ms/swa/ThisMonth
https://aka.ms/swa
MIT License
330 stars 57 forks source link

What's the output_location parameter in generated workflow file? #201

Closed dzeyelid closed 3 years ago

dzeyelid commented 4 years ago

When I deploy an Azure Static Web Apps with Azure CLI or ARM template, the generated workflow file includes output_location instead of app_artifact_location.

GitHub Action shows Warning: Unexpected input(s) 'output_location' when the workflow run, but the output_location seems to work as app_artifact_location. for evidence, if remove the output_location parameter, the following error occurred.

---End of Oryx build logs---
Oryx built the app folder but was unable to determine the location of the app artifacts. Please specify the app artifact location through the Github workflow file.

I tested these behaviors on this repository that is based on vue-basic template.

This is a command to deploy the static web apps for the repository above at first.

az staticwebapp create -n static-test -g <resource group> -s https://github.com/dzeyelid/staticwebapps-test --token <token> -l eastasia -b master --app-artifact-location dist

Then I tested whether the output_location works correctly on this pull request. https://github.com/dzeyelid/staticwebapps-test/pull/2

In addition, the ARM template that makes the same situation is here. This template is based on this syntax. https://github.com/dzeyelid/line-liff-with-azure-handson/blob/main/arm-templates/template.json

These behaviors make us confused, so I would like you to confirm it.

Thanks.

miwebst commented 4 years ago

Yes they are the same, app_artifact_location == output_location. We realized that app artifact location is slightly confusing so we are starting to change this to output_location.

@craigshoemaker we should probably document this in the docs and once our release is finished we should mark app_artifact_location as deprecated in favor of output_location.

Both of these will continue to work in the ARM, CLI, and Portal, as well as any existing workflows you already have. I will make the necessary changes to make sure the action does not throw this warning.

Thanks for surfacing this!

dzeyelid commented 4 years ago

@miwebst Thanks for responding and for the improvement. I understood that.

miwebst commented 4 years ago

The warnings should be gone now, going to keep this open until we get the docs updated.

miwebst commented 3 years ago

This has been documented!