Skip to content

Commit

Permalink
Fix Unix deployment of frontend (microsoft#194)
Browse files Browse the repository at this point in the history
### Motivation and Context
I introduced a bug with
microsoft#165 in the frontend
deployment script

### Description
Use proper Unix commands in the shell script

### Contribution Checklist
- [ ] The code builds clean without any errors or warnings
- [ ] The PR follows the [Contribution
Guidelines](https://github.com/microsoft/copilot-chat/blob/main/CONTRIBUTING.md)
and the [pre-submission formatting
script](https://github.com/microsoft/copilot-chat/blob/main/CONTRIBUTING.md#development-scripts)
raises no violations
- [ ] All unit tests pass, and I have added new tests where possible
- [ ] I didn't break anyone 😄
  • Loading branch information
glahaye authored Aug 16, 2023
1 parent 0ab7e66 commit 20e124d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/copilot-deploy-frontend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,12 +82,12 @@ jobs:
- name: Set version tag
id: versiontag
run: |
$VERSION_TAG = "${{ steps.gitversion.outputs.Major }}."
$VERSION_TAG += "${{ steps.gitversion.outputs.Minor }}."
$VERSION_TAG += "${{ steps.gitversion.outputs.CommitsSinceVersionSource }}"
VERSION_TAG="${{ steps.gitversion.outputs.Major }}."
VERSION_TAG+="${{ steps.gitversion.outputs.Minor }}."
VERSION_TAG+="${{ steps.gitversion.outputs.CommitsSinceVersionSource }}"
echo $VERSION_TAG
Write-Output "versiontag=$VERSION_TAG" >> $env:GITHUB_OUTPUT
echo "versiontag=$VERSION_TAG" >> "$GITHUB_OUTPUT"
- name: Deploy SWA
run: |
scripts/deploy/deploy-webapp.sh --subscription ${{secrets.AZURE_SUBSCRIPTION_ID}} --resource-group ${{vars.CC_DEPLOYMENT_GROUP_NAME}} --deployment-name ${{inputs.DEPLOYMENT_NAME}} --application-id ${{vars.APPLICATION_CLIENT_ID}} --authority ${{secrets.APPLICATION_AUTHORITY}} --no-redirect -version ${{ steps.versiontag.outputs.versiontag }} -version-info "Built from commit ${{ steps.gitversion.outputs.ShortSha }} on $(Get-Date -Format "yyyy-MM-dd")"
scripts/deploy/deploy-webapp.sh --subscription ${{secrets.AZURE_SUBSCRIPTION_ID}} --resource-group ${{vars.CC_DEPLOYMENT_GROUP_NAME}} --deployment-name ${{inputs.DEPLOYMENT_NAME}} --application-id ${{vars.APPLICATION_CLIENT_ID}} --authority ${{secrets.APPLICATION_AUTHORITY}} --no-redirect --version ${{ steps.versiontag.outputs.versiontag }} --version-info "Built from commit ${{ steps.gitversion.outputs.ShortSha }} on $(date +"%Y-%m-%d")"
4 changes: 2 additions & 2 deletions scripts/deploy/deploy-webapp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ while [[ $# -gt 0 ]]; do
shift
shift
;;
-i|--version-nfo)
-i|--version-info)
VERSION_INFO="$2"
shift
shift
Expand Down Expand Up @@ -177,4 +177,4 @@ if [ "$NO_REDIRECT" != true ]; then
fi
fi

echo "To verify your deployment, go to 'https://$WEB_APP_URL' in your browser."
echo "To verify your deployment, go to 'https://$WEB_APP_URL' in your browser."

0 comments on commit 20e124d

Please sign in to comment.