%3CLINGO-SUB%20id%3D%22lingo-sub-1453991%22%20slang%3D%22en-US%22%3EEnable%20CI%2FCD%20for%20Windows%20apps%20with%20GitHub%20Actions%20and%20Azure%20Static%20Web%20Apps%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1453991%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fstatic-web-apps%2Foverview%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3EAzure%20Static%20Web%20Apps%3C%2FA%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eis%20a%20new%20Azure%20service%20launched%20in%20Preview%20at%20Build%202020%2C%20which%20offers%20an%20app%20service%20dedicated%20to%20static%20websites.%20You%20could%20say%20%22why%20is%20it%20so%20special%22%3F%20In%20the%20end%2C%20hosting%20a%20static%20website%20is%20relatively%20simple%2C%20since%20there%20isn't%20any%20server-side%20component%3A%20no%20databases%2C%20no%20ASP.NET%20Core%20or%20PHP%20or%20Node%20runtime%2C%20just%20pure%20HTML%2C%20CSS%20and%20JavaScript.%20Azure%20Static%20Web%20Apps%20is%20more%20than%20just%20hosting%20for%20static%20content%3A%20thanks%20to%20its%20tight%20connection%20to%20GitHub%2C%20it%20supports%20creating%20automated%20pipelines%20(through%20GitHub%20Actions)%20which%20are%20able%20to%20automatically%20build%20and%20deploy%20full%20stack%20web%20apps.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThis%20service%20is%20a%20great%20companion%20for%20frameworks%20like%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fstatic-web-apps%2Fpublish-gatsby%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3EGatsby%3C%2FA%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eor%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fstatic-web-apps%2Fpublish-hugo%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3EHugo%3C%2FA%3E%2C%20which%20are%20able%20to%20generate%20static%20pages%20as%20part%20of%20the%20build%20process.%20Let's%20say%20that%20you're%20using%20Hugo%20to%20host%20your%20personal%20blog.%20Thanks%20to%20Azure%20Static%20Web%20App%2C%20you%20can%20just%20simply%20commit%20to%20your%20GitHub%20repository%20a%20markdown%20file%20with%20your%20latest%20post%20to%20trigger%20the%20execution%20of%20a%20GitHub%20Action%2C%20which%20will%20build%20it%20as%20a%20static%20page.%3C%2FP%3E%0A%3CP%3EAnd%20if%20you%20need%20to%20add%20a%20server-side%20component%20(for%20example%2C%20hosting%20a%20REST%20API)%2C%20the%20Azure%20Static%20Web%20App%20service%20supports%20the%20deployment%20of%20serverless%20APIs%20based%20on%20Azure%20Functions.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EHowever%2C%20as%20you%20know%2C%20in%20my%20everyday%20job%20I'm%20focused%20on%20the%20development%20and%20the%20deployment%20of%20Windows%20desktop%20applications.%20And%2C%20as%20you%20probably%20know%20if%20you%20follow%20this%20blog%20or%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fwww.syncfusion.com%2Febooks%2Fmsix-succinctly%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3Eif%20you%20have%20read%20my%20book%20about%20MSIX%3C%2FA%3E%2C%20I'm%20a%20big%20fan%20of%20MSIX%20and%20the%20App%20Installer%20technology%2C%20which%20enables%20to%20easily%20have%20a%20solid%20CI%2FCD%20story%20for%20Windows%20applications.%20Thanks%20to%20them%2C%20in%20fact%2C%20we%20can%20enable%20features%20like%20automatic%20updates%2C%20critical%20updates%2C%20differential%20updates%2C%20etc.%20And%20guess%20what%3F%20All%20you%20need%20is%20a%20static%20website%20that%20can%20host%20your%20MSIX%20package%2C%20plus%20the%20AppInstaller%20file.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EI%20guess%20now%20you%20know%20where%20I'm%20headed%20to%20%3D)%3C%2Fimg%3E%20Let's%20see%20how%20we%20can%20use%20an%20Azure%20Static%20Web%20App%20to%20host%20our%20MSIX%20package%2C%20which%20will%20be%20automatically%20built%20and%20deployed%20by%20a%20GitHub%20Action.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CH3%20id%3D%22set-up-the-azure-static-web-app%22%20id%3D%22toc-hId-1172152913%22%20id%3D%22toc-hId-1172152914%22%3ESet%20up%20the%20Azure%20Static%20Web%20App%3C%2FH3%3E%0A%3CP%3EAs%20first%20step%2C%20let's%20create%20our%20Azure%20Static%20Web%20App.%20Login%20to%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fportal.azure.com%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3EAzure%20portal%3C%2FA%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Ewith%20your%20account%20and%20click%20on%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3ECreate%20a%20resource%3C%2FSTRONG%3E.%20Start%20a%20search%20using%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3Estatic%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Ekeyword.%20One%20of%20the%20results%20will%20be%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3EStatic%20Web%20App%20(Preview)%3C%2FSTRONG%3E%2C%20as%20in%20the%20following%20image%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22NewStaticWebApp.png%22%20style%3D%22width%3A%20896px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F197910i54A5339C2D163889%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22NewStaticWebApp.png%22%20alt%3D%22NewStaticWebApp.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%3EClick%20on%20it%20and%20choose%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3ECreate%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3Bto%20start%20the%20process%3A%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22CreateNewApp.png%22%20style%3D%22width%3A%20793px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F197911i38747EFF82490AD6%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22CreateNewApp.png%22%20alt%3D%22CreateNewApp.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%3EThe%20first%20information%20you%20have%20to%20provide%20are%20the%20subscription%2C%20the%20resource%20group%2C%20the%20name%20of%20the%20app%20and%20the%20region.%20The%20only%20available%20SKU%2C%20for%20the%20moment%2C%20is%20the%20Free%20one%2C%20since%20the%20service%20is%20in%20preview.%20Currently%20this%20service%20works%20only%20with%20GitHub%2C%20since%20it%20doesn't%20use%20it%20just%20to%20connect%20to%20the%20repository%2C%20but%20it's%20going%20to%20create%20the%20GitHub%20Action%20needed%20to%20compile%20and%20deploy%20the%20project%20for%20us.%20As%20such%2C%20the%20next%20required%20step%20is%20to%20click%20on%26nbsp%3B%3CSTRONG%3ESign%20in%20with%20GitHub%3C%2FSTRONG%3E%26nbsp%3Bto%20complete%20the%20login%20process%20with%20your%20GitHub%20account.%20Once%20you%20are%20logged%20in%2C%20you%20will%20have%20the%20opportunity%20to%20choose%20an%20organization%2C%20a%20repository%20and%20a%20branch%20from%20the%20ones%20have%20on%20GitHub%3A%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22GitHubSetup.png%22%20style%3D%22width%3A%20772px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F197912i671512D98ADD3397%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22GitHubSetup.png%22%20alt%3D%22GitHubSetup.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EFor%20our%20scenario%20we're%20going%20to%20choose%20a%20repository%20which%20contains%20a%20.NET%20Desktop%20application%20packaged%20with%20the%20Windows%20Application%20Packaging%20Project.%20The%20one%20I'm%20using%20for%20this%20blog%20post%20is%20available%20at%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fqmatteoq%2FContosoApp%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fgithub.com%2Fqmatteoq%2FContosoApp%3C%2FA%3E.%20It's%20just%20a%20plain%20WPF%20application%20based%20on%20.NET%20Core%203.1.%3C%2FP%3E%0A%3CP%3EOnce%20you%20have%20completed%20the%20configuration%2C%20press%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3EReview%20%2B%20create%3C%2FSTRONG%3E%2C%20followed%20by%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3ECreate%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Ein%20the%20review%20page.%20Once%20the%20deployment%20has%20been%20completed%2C%20you%20will%20notice%20a%20few%20changes%20in%20your%20GitHub%20repository%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%3CP%3EThere%20will%20be%20a%20new%20folder%2C%20called%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Egithub%2Fworkflows%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Ewith%20a%20YAML%20file%20inside.%20That's%20our%20GitHub%20workflow.%20We%20can%20see%20it%20also%20by%20clicking%20on%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3EActions%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Etab%20in%20the%20repository%3A%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22GitHubAction.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F197913i0E52C884CD0E33C9%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22GitHubAction.png%22%20alt%3D%22GitHubAction.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3EThe%20workflow%20is%20called%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3EAzure%20Static%20Web%20Apps%20CI%2FCD%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eand%20it%20will%20be%20executed%20immediately.%20However%2C%20it%20will%20fail%2C%20since%20our%20repository%20contains%20a%20desktop%20application%20and%20the%20default%20workflow%20isn't%20tailored%20for%20this%20scenario.%20Don't%20worry%2C%20we're%20going%20to%20fix%20that!%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3EIf%20you%20go%20to%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3ESettings%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Esection%20of%20the%20repository%20and%20you%20move%20to%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3ESecrets%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Etab%2C%20you%20will%20find%20out%20that%20Azure%20Static%20Web%20App%20has%20added%20a%20new%20secret%20for%20you%3A%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22Secret.png%22%20style%3D%22width%3A%20759px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F197914i584E2D6A7214E34B%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22Secret.png%22%20alt%3D%22Secret.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSPAN%3EThis%20secret%20contains%20the%20API%20token%20which%20is%20required%20by%20the%20GitHub%20Action%20to%20connect%20to%20the%20Azure%20Static%20Web%20App%20instance%20we%20have%20created%2C%20in%20order%20to%20perform%20the%20deployment.%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CH3%20id%3D%22customize-the-workflow%22%20id%3D%22toc-hId--635301550%22%20id%3D%22toc-hId--635301549%22%3ECustomize%20the%20workflow%3C%2FH3%3E%0A%3CP%3ELet's%20take%20a%20look%20at%20the%20workflow%20that%20the%20Azure%20Static%20Web%20App%20has%20created%20for%20us%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22language-yaml%20hljs%22%3E%3CSPAN%20class%3D%22hljs-attr%22%3Ename%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EAzure%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EStatic%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EWeb%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EApps%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ECI%2FCD%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3Eon%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20push%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20branches%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-bullet%22%3E%20%20%20%20%20%20-%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emaster%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20pull_request%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20types%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5Bopened%2C%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Esynchronize%2C%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ereopened%2C%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eclosed%5D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20branches%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-bullet%22%3E%20%20%20%20%20%20-%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emaster%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3Ejobs%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20build_and_deploy_job%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20if%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Egithub.event_name%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%3D%3D%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E'push'%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7C%7C%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E(github.event_name%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%3D%3D%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E'pull_request'%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%26amp%3B%26amp%3B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Egithub.event.action%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E!%3D%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E'closed'%3C%2FSPAN%3E%3CSPAN%20class%3D%22hljs-string%22%3E)%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20runs-on%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eubuntu-latest%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EBuild%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eand%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EDeploy%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EJob%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20steps%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20-%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eactions%2Fcheckout%40v2%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20with%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20%20%20submodules%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-literal%22%3Etrue%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EBuild%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EAnd%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EDeploy%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20id%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ebuilddeploy%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EAzure%2Fstatic-web-apps-deploy%40v0.0.1-preview%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20with%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20%20%20azure_static_web_apps_api_token%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Esecrets.AZURE_STATIC_WEB_APPS_API_TOKEN_CALM_DESERT_05F99C503%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20%20%20repo_token%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Esecrets.GITHUB_TOKEN%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Used%20for%20Github%20integrations%20(i.e.%20PR%20comments)%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20%20%20action%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%22upload%22%3C%2FSPAN%3E%0A%20%20%20%20%20%20%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%23%23%23%23%23%20Repository%2FBuild%20Configurations%20-%20These%20values%20can%20be%20configured%20to%20match%20you%20app%20requirements.%20%23%23%23%23%23%23%3C%2FSPAN%3E%0A%20%20%20%20%20%20%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20For%20more%20information%20regarding%20Static%20Web%20App%20workflow%20configurations%2C%20please%20visit%3A%20https%3A%2F%2Faka.ms%2Fswaworkflowconfig%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20%20%20app_location%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%22%2F%22%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20App%20source%20code%20path%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20%20%20api_location%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%22api%22%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Api%20source%20code%20path%20-%20optional%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20%20%20app_artifact_location%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%22%22%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Built%20app%20content%20directory%20-%20optional%3C%2FSPAN%3E%0A%20%20%20%20%20%20%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%23%23%23%23%23%20End%20of%20Repository%2FBuild%20Configurations%20%23%23%23%23%23%23%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20close_pull_request_job%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20if%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Egithub.event_name%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%3D%3D%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E'pull_request'%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%26amp%3B%26amp%3B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Egithub.event.action%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%3D%3D%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E'closed'%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20runs-on%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eubuntu-latest%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EClose%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EPull%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ERequest%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EJob%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20steps%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EClose%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EPull%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ERequest%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20id%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eclosepullrequest%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EAzure%2Fstatic-web-apps-deploy%40v0.0.1-preview%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20with%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20%20%20azure_static_web_apps_api_token%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Esecrets.AZURE_STATIC_WEB_APPS_API_TOKEN_CALM_DESERT_05F99C503%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20%20%20action%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%22close%22%3C%2FSPAN%3E%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3EThe%20workflow%20contains%20two%20distinct%20jobs%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%3CSTRONG%3Ebuild_and_deploy_job%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eis%20triggered%20whenever%20you%20submit%20a%20new%20Pull%20Request%20to%20the%20repository.%20The%20goal%20of%20this%20job%20is%20to%20build%20the%20updated%20website%20included%20in%20the%20Pull%20Request%20and%20to%20deploy%20it%20in%20a%20staging%20environment%2C%20so%20that%20you%20can%20test%20that%20everything%20is%20working%20as%20expected.%3C%2FLI%3E%0A%3CLI%3E%3CSTRONG%3Eclose_pull_request_job%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eis%20triggered%20whenever%20you%20close%20a%20Pull%20Request.%20This%20means%20that%20the%20you%20have%20validated%20that%20the%20Pull%20Request%20is%20good%20and%2C%20as%20such%2C%20the%20staging%20environment%20can%20be%20deleted%20because%20the%20new%20version%20of%20the%20website%20can%20be%20safely%20pushed%20to%20production.%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3EAs%20you%20can%20imagine%2C%20however%2C%20for%20our%20scenario%20this%20isn't%20really%20applicable%2C%20since%20we%20aren't%20really%20deploying%20a%20website%2C%20but%20a%20desktop%20application%20to%20be%20deployed.%20As%20such%2C%20we're%20going%20to%20basically%20delete%20everything%20from%20this%20workflow%20file%2C%20except%20for%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3EBuild%20and%20deploy%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Etask%2C%20which%20is%20based%20on%20the%20action%20called%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3EAzure%2Fstatic-web-apps-deploy%40v0.0.1-preview%3C%2FSTRONG%3E.%20We're%20going%20to%20use%20this%20one%20to%20publish%20the%20output%20of%20the%20Visual%20Studio%20compilation%3A%20the%20MSIX%20package%2C%20the%20AppInstaller%20file%20and%20the%20web%20page%20to%20trigger%20the%20installation.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ETo%20customize%20the%20workflow%2C%20we're%20going%20to%20take%20inspiration%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fdevblogs.microsoft.com%2Fdotnet%2Fcontinuous-integration-workflow-template-for-net-core-desktop-apps-with-github-actions%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Efrom%20the%20template%20created%20by%20.NET%20Team%3C%2FA%3E%2C%20which%20is%20a%20great%20starting%20point%20when%20you%20want%20to%20build%20desktop%20.NET%20Core%20applications%20on%20GitHub.%20This%20template%20perfectly%20fits%20my%20scenario%3A%20I%20have%20a%20WPF%20application%20based%20on%20.NET%20Core%20and%20a%20Windows%20Application%20Packaging%20Project%20to%20generate%20the%20MSIX%20package.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ELet's%20start%20by%20creating%20a%20copy%20of%20the%20existing%20workflow%20file.%20We're%20going%20to%20need%20it%20later.%20Now%20open%20on%20GitHub%20the%20workflow%20file%20(in%20my%20case%2C%20it's%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fqmatteoq%2FContosoApp%2Fblob%2Fmaster%2F.github%2Fworkflows%2Fazure-static-web-apps-calm-desert-05f99c503.yml%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fgithub.com%2Fqmatteoq%2FContosoApp%2Fblob%2Fmaster%2F.github%2Fworkflows%2Fazure-static-web-apps-calm-desert-05f99c503.yml%3C%2FA%3E)%20and%20click%20on%20the%20edit%20icon%20(the%20small%20pencil%20in%20the%20toolbar)%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22EditFile.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F197915i2DA6FA4BC78F726E%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22EditFile.png%22%20alt%3D%22EditFile.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%3EWhen%20you%20do%20this%2C%20GitHub%20will%20propose%20you%20a%20special%20edit%20interface%20tailored%20for%20workflows.%20Thanks%20a%20to%20a%20panel%20on%20the%20right%2C%20you'll%20be%20able%20to%20easily%20browse%20the%20Actions%20marketplace%20and%20integrate%20tasks%20in%20the%20workflow.%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22EditGitHubAction.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F197916i0D83E64DB78A3BB0%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22EditGitHubAction.png%22%20alt%3D%22EditGitHubAction.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EFor%20the%20moment%2C%20let's%20delete%20everything%20(except%20for%20the%20first%20line%20which%20defines%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Ename%3C%2FCODE%3E)%20and%20replace%20the%20content%20with%20the%20one%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Factions%2Fstarter-workflows%2Fblob%2Fmaster%2Fci%2Fdotnet-core-desktop.yml%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Efrom%20the%20.NET%20Desktop%20workflow%3C%2FA%3E.%20This%20is%20how%20your%20workflow%20should%20look%20like%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22language-yaml%20hljs%22%3E%3CSPAN%20class%3D%22hljs-attr%22%3Ename%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EAzure%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EStatic%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EWeb%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EApps%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ECI%2FCD%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3Eon%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20push%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20branches%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emaster%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20pull_request%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20branches%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emaster%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5D%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3Ejobs%3A%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20build%3A%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20strategy%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20matrix%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20configuration%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5BDebug%2C%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ERelease%5D%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20runs-on%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ewindows-latest%3C%2FSPAN%3E%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20For%20a%20list%20of%20available%20runner%20types%2C%20refer%20to%20%3C%2FSPAN%3E%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20https%3A%2F%2Fhelp.github.com%2Fen%2Factions%2Freference%2Fworkflow-syntax-for-github-actions%23jobsjob_idruns-on%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20env%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20Solution_Name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eyour-solution-name%3C%2FSPAN%3E%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Replace%20with%20your%20solution%20name%2C%20i.e.%20MyWpfApp.sln.%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20Test_Project_Path%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eyour-test-project-path%3C%2FSPAN%3E%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Replace%20with%20the%20path%20to%20your%20test%20project%2C%20i.e.%20MyWpfApp.Tests%5CMyWpfApp.Tests.csproj.%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20Wap_Project_Directory%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eyour-wap-project-directory-name%3C%2FSPAN%3E%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Replace%20with%20the%20Wap%20project%20directory%20relative%20to%20the%20solution%2C%20i.e.%20MyWpfApp.Package.%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20Wap_Project_Path%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eyour-wap-project-path%3C%2FSPAN%3E%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Replace%20with%20the%20path%20to%20your%20Wap%20project%2C%20i.e.%20MyWpf.App.Package%5CMyWpfApp.Package.wapproj.%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20steps%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ECheckout%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eactions%2Fcheckout%40v2%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20with%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20fetch-depth%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-number%22%3E0%3C%2FSPAN%3E%0A%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Install%20the%20.NET%20Core%20workload%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EInstall%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E.NET%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ECore%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eactions%2Fsetup-dotnet%40v1%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20with%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20dotnet-version%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-number%22%3E3.1%3C%2FSPAN%3E%3CSPAN%20class%3D%22hljs-number%22%3E.101%3C%2FSPAN%3E%0A%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Add%20%20MSBuild%20to%20the%20PATH%3A%20https%3A%2F%2Fgithub.com%2Fmicrosoft%2Fsetup-msbuild%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ESetup%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EMSBuild.exe%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emicrosoft%2Fsetup-msbuild%402008f912f56e61277eefaac6d1888b750582aa16%3C%2FSPAN%3E%0A%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Execute%20all%20unit%20tests%20in%20the%20solution%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EExecute%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eunit%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Etests%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20run%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Edotnet%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Etest%3C%2FSPAN%3E%0A%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Restore%20the%20application%20to%20populate%20the%20obj%20folder%20with%20RuntimeIdentifiers%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ERestore%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ethe%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eapplication%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20run%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emsbuild%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24env%3ASolution_Name%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Ft%3ARestore%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AConfiguration%3D%24env%3AConfiguration%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20env%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20Configuration%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ematrix.configuration%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%0A%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Decode%20the%20base%2064%20encoded%20pfx%20and%20save%20the%20Signing_Certificate%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EDecode%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ethe%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Epfx%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20run%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7C%0A%20%20%20%20%20%20%20%20%24pfx_cert_byte%20%3D%20%5BSystem.Convert%5D%3A%3AFromBase64String(%22%24%3CSPAN%20class%3D%22hljs-template-variable%22%3E%7B%7B%20secrets.Base64_Encoded_Pfx%20%7D%7D%3C%2FSPAN%3E%22)%0A%20%20%20%20%20%20%20%20%24certificatePath%20%3D%20Join-Path%20-Path%20%24env%3AWap_Project_Directory%20-ChildPath%20GitHubActionsWorkflow.pfx%0A%20%20%20%20%20%20%20%20%5BIO.File%5D%3A%3AWriteAllBytes(%22%24certificatePath%22%2C%20%24pfx_cert_byte)%0A%0A%20%20%20%20%23%20Create%20the%20app%20package%20by%20building%20and%20packaging%20the%20Windows%20Application%20Packaging%20project%0A%3C%2FSPAN%3E%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ECreate%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ethe%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eapp%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Epackage%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20run%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emsbuild%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24env%3AWap_Project_Path%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AConfiguration%3D%24env%3AConfiguration%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AUapAppxPackageBuildMode%3D%24env%3AAppx_Package_Build_Mode%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AAppxBundle%3D%24env%3AAppx_Bundle%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3APackageCertificateKeyFile%3DGitHubActionsWorkflow.pfx%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3APackageCertificatePassword%3D%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Esecrets.Pfx_Key%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20env%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20Appx_Bundle%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EAlways%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20Appx_Bundle_Platforms%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ex86%7Cx64%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20Appx_Package_Build_Mode%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EStoreUpload%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20Configuration%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ematrix.configuration%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%0A%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Remove%20the%20pfx%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ERemove%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ethe%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Epfx%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20run%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ERemove-Item%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-bullet%22%3E-path%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24env%3AWap_Project_Directory%5C%24env%3ASigning_Certificate%3C%2FSPAN%3E%0A%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Upload%20the%20MSIX%20package%3A%20https%3A%2F%2Fgithub.com%2Fmarketplace%2Factions%2Fupload-artifact%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EUpload%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ebuild%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eartifacts%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eactions%2Fupload-artifact%40v1%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20with%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EMSIX%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EPackage%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20path%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eenv.Wap_Project_Directory%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%5CAppPackages%3C%2FSPAN%3E%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3ELet's%20go%20and%20customize%20a%20few%20things.%20First%2C%20you'll%20need%20to%20customize%20the%20environment%20variables%20defined%20at%20the%20top%20to%20point%20to%20your%20solutions%20and%20project.%20You'll%20have%20to%20setup%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%3CCODE%3ESolution_Name%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Ewith%20the%20relative%20path%20of%20the%20solution%20file%3C%2FLI%3E%0A%3CLI%3E%3CCODE%3EWap_Project_Directory%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Ewith%20the%20relative%20path%20of%20the%20folder%20which%20contains%20the%20Windows%20Application%20Packaging%20Project%3C%2FLI%3E%0A%3CLI%3E%3CCODE%3EWap_Project_Path%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Ewith%20the%20full%20path%20of%20Windows%20Application%20Packaging%20Project%20file%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3EOptionally%2C%20you%20can%20also%20use%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3ETest_Project_Path%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eto%20configure%20the%20path%20of%20the%20project%20which%20contains%20your%20unit%20tests.%20In%20my%20case%2C%20since%20it's%20a%20sample%20project%2C%20I%20don't%20have%20one%2C%20so%20I%20simply%20removed%20that%20variable.%20This%20is%20how%20my%20environment%20configuration%20looks%20like%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22language-yaml%20hljs%22%3E%3CSPAN%20class%3D%22hljs-attr%22%3Eenv%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20Solution_Name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EContosoApp.sln%3C%2FSPAN%3E%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20Wap_Project_Directory%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EContosoApp.Package%3C%2FSPAN%3E%20%20%20%20%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20Wap_Project_Path%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EContosoApp.Package%5CContosoApp.Package.wapproj%3C%2FSPAN%3E%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3ESecond%2C%20for%20our%20scenario%2C%20we%20don't%20really%20need%20to%20build%20the%20application%20both%20in%20Debug%20and%20Release%20mode.%20We%20just%20want%20to%20have%2C%20as%20output%2C%20a%20single%20release%20MSIX%20package%2C%20so%20that%20we%20can%20deploy%20it%20on%20our%20website.%20As%20such%2C%20remove%20from%20the%20configuration%20matrix%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3EDebug%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eentry%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22language-yaml%20hljs%22%3E%3CSPAN%20class%3D%22hljs-attr%22%3Estrategy%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20matrix%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20configuration%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5BRelease%5D%3C%2FSPAN%3E%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3EAs%20next%20step%2C%20I'm%20going%20to%20customize%20some%20of%20the%20available%20tasks%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3E%3CCODE%3EExecute%20unit%20tests%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eisn't%20needed%20for%20my%20sample%20application%2C%20since%20I%20don't%20have%20unit%20tests.%20As%20such%2C%20I'm%20going%20to%20delete%20this%20one.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3E%3CCODE%3EBuild%3C%2FCODE%3E.%20Since%20we're%20going%20to%20use%20the%20AppInstaller%20technology%20to%20distribute%20the%20package%20using%20our%20Azure%20Static%20Web%20App%2C%20we%20need%20to%20tweak%20a%20bit%20the%20various%20parameters.%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3EThe%20first%20one%20is%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3EAppx_Package_Build_Mode%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eparameter%2C%20which%20by%20default%20is%20set%20to%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3EStoreUpload%3C%2FCODE%3E%2C%20which%20is%20the%20needed%20when%20you%20want%20to%20publish%20the%20application%20on%20the%20Microsoft%20Store.%20In%20this%20case%20we're%20using%20manual%20distribution%2C%20so%20we%20need%20to%20change%20it%20to%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3ESideloadOnly%3C%2FCODE%3E.%3C%2FLI%3E%0A%3CLI%3EWe%20need%20to%20add%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3E%2Fp%3AGenerateAppInstallerFile%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eparameter%20and%20set%20it%20to%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Etrue%3C%2FCODE%3E%2C%20in%20order%20to%20generate%20the%20.appinstaller%20file%20and%20the%20web%20page%20as%20part%20of%20the%20process.%3C%2FLI%3E%0A%3CLI%3EWe%20need%20to%20add%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3E%2Fp%3AAppInstallerUri%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eparameter%20and%20set%20it%20to%20the%20URL%20that%20has%20been%20assigned%20to%20our%20Azure%20Static%20Web%20App.%20You%20can%20find%20this%20URL%20in%20the%20Azure%20portal%3A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22AzureAppUrl.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F197917i01E0CD8BEE56938A%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22AzureAppUrl.png%22%20alt%3D%22AzureAppUrl.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThis%20is%20how%20the%20task%20looks%20like%20after%20the%20changes%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22language-yaml%20hljs%22%3E%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Create%20the%20app%20package%20by%20building%20and%20packaging%20the%20Windows%20Application%20Packaging%20project%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ECreate%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ethe%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eapp%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Epackage%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20run%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emsbuild%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24env%3AWap_Project_Path%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AConfiguration%3D%24env%3AConfiguration%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AUapAppxPackageBuildMode%3D%24env%3AAppx_Package_Build_Mode%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AAppxBundle%3D%24env%3AAppx_Bundle%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AGenerateAppInstallerFile%3D%24env%3AGenerate_AppInstaller%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AAppInstallerUri%3D%24env%3AAppInstaller_Url%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3APackageCertificateKeyFile%3DGitHubActionsWorkflow.pfx%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3APackageCertificatePassword%3D%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Esecrets.Pfx_Key%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20env%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20Appx_Bundle%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EAlways%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20Appx_Bundle_Platforms%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ex86%7Cx64%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20Appx_Package_Build_Mode%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ESideloadOnly%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20Configuration%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ematrix.configuration%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20Generate_AppInstaller%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-literal%22%3Etrue%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20AppInstaller_Url%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-attr%22%3Ehttps%3A%2F%2Fcalm-desert-05f99c503.azurestaticapps.net%3C%2FSPAN%3E%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CH3%20id%3D%22setting-up-the-signing%22%20id%3D%22toc-hId-1852211283%22%20id%3D%22toc-hId-1852211284%22%3ESetting%20up%20the%20signing%3C%2FH3%3E%0A%3CP%3EAs%20I%20have%20discussed%20multiple%20times%20in%20this%20blog%2C%20signing%20is%20a%20critical%20aspect%20of%20MSIX%20packaging.%20If%20you%20don't%20sign%20a%20MSIX%20package%20with%20a%20trusted%20certificate%2C%20the%20user%20will%20never%20be%20able%20to%20install%20it.%20At%20the%20same%20time%2C%20you%20must%20be%20very%20careful%20in%20how%20you%20enable%20signing%20as%20part%20of%20a%20CI%2FCD%20pipeline.%20If%20you%20expose%20your%20private%20certificate%2C%20someone%20might%20be%20able%20to%20steal%20it%20and%20use%20your%20identity%20to%20sign%20malicious%20applications.%20There%20are%20multiple%20approaches%20to%20sign%20MSIX%20packages%20in%20the%20right%20way%20as%20part%20of%20a%20CI%2FCD%20pipeline.%20The%20approach%20used%20by%20the%20workflow%20template%20is%20to%20ask%20to%20the%20developer%20to%20encode%20the%20PFX%20into%20a%20base64%20string%20and%20store%20it%20as%20a%20secret.%20Then%20the%20workflow%20includes%20a%20PowerShell%20script%20which%20takes%20care%20of%20decoding%20the%20secret%20back%20into%20a%20PFX%2C%20so%20that%20it%20can%20be%20used%20as%20part%20of%20the%20Visual%20Studio%20build%20to%20do%20the%20signing.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20main%20reasoning%20of%20using%20this%20approach%20on%20GitHub%20is%20that%2C%20unlike%20Azure%20DevOps%2C%20the%20platform%20doesn't%20have%20the%20concept%20of%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fdevops%2Fpipelines%2Flibrary%2Fsecure-files%3Fview%3Dazure-devops%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3ESecure%20Files%3C%2FA%3E%2C%20which%20is%20often%20used%20in%20scenarios%20like%20this%20one.%3C%2FP%3E%0A%3CP%3EThe%20GitHub%20Action%20workflow%20already%20contains%20everything%20you%20need%20to%20sign%20the%20package.%20The%20only%20missing%20step%20is%20to%20create%20the%20secrets%20to%20store%20the%20various%20required%20information.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3COL%3E%0A%3CLI%3E%0A%3CP%3EOpen%20a%20PowerShell%20terminal%20in%20the%20folder%20in%20which%20you%20keep%20your%20PFX%20certificate.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3ERun%20the%20following%20script%3A%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22language-powershell%20hljs%22%3E%3CSPAN%20class%3D%22hljs-variable%22%3E%24pfx_cert%3C%2FSPAN%3E%20%3D%20%3CSPAN%20class%3D%22hljs-built_in%22%3EGet-Content%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E'.%5CSigningCertificate.pfx'%3C%2FSPAN%3E%20-Encoding%20Byte%0A%5BSystem.Convert%5D%3A%3AToBase64String(%3CSPAN%20class%3D%22hljs-variable%22%3E%24pfx_cert%3C%2FSPAN%3E)%20%7C%20%3CSPAN%20class%3D%22hljs-built_in%22%3EOut-File%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E'SigningCertificate_Encoded.txt'%3C%2FSPAN%3E%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3EAt%20the%20end%20of%20the%20process%20you%20will%20find%2C%20in%20the%20same%20folder%2C%20a%20text%20file%20called%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3ESigningCertificate_Encoded.txt%3C%2FSTRONG%3E%2C%20which%20contains%20the%20certificate%20encoded%20as%20a%20base64%20string.%20Open%20the%20text%20file%20and%20copy%20the%20whole%20content.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3ENow%20go%20to%20your%20repository%20on%20GitHub%2C%20choose%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3ESettings%20%E2%86%92%20Secrets%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eand%20create%20a%20new%20secret.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3ECall%20the%20secret%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3EBase64_Encoded_Pfx%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eand%2C%20as%20value%2C%20paste%20the%20encoded%20base64%20string%20you%20have%20just%20copied.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3ENow%20create%20a%20new%20secret%20and%20call%20it%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3EPfx_Key%3C%2FCODE%3E.%20As%20value%2C%20type%20the%20password%20for%20the%20signing%20certificate.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FOL%3E%0A%3CP%3EThat's%20it.%20Another%20and%20safer%20alternative%20to%20this%20approach%20is%20to%20leverage%20Azure%20Key%20Vault%20to%20store%20your%20certificate%20and%20the%20Azure%20SignTool%20utility%20to%20do%20the%20actual%20signing%20as%20part%20of%20the%20pipeline.%20You%20can%20find%20all%20the%20details%20about%20this%20approach%2C%20including%20how%20to%20use%20it%20in%20a%20GitHub%20Action%20workflow%2C%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fwindows-dev-appconsult%2Fsigning-a-msix-package-with-azure-key-vault%2Fba-p%2F1436154%22%20target%3D%22_blank%22%3Ein%20a%20recent%20blog%20post%20I%20wrote%3C%2FA%3E.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CH3%20id%3D%22reviewing-the-pipeline%22%20id%3D%22toc-hId-44756820%22%20id%3D%22toc-hId-44756821%22%3EReviewing%20the%20pipeline%3C%2FH3%3E%0A%3CP%3EWe%20have%20finished%20the%20work%20on%20the%20build%20pipeline.%20This%20is%20how%20it%20should%20look%20like%20after%20the%20changes%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22language-yaml%20hljs%22%3E%3CSPAN%20class%3D%22hljs-attr%22%3Ename%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EAzure%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EStatic%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EWeb%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EApps%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ECI%2FCD%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3Eon%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20push%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20branches%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emaster%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20pull_request%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20branches%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emaster%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5D%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3Ejobs%3A%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20build%3A%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20strategy%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20matrix%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20configuration%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5BRelease%5D%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20runs-on%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ewindows-latest%3C%2FSPAN%3E%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20For%20a%20list%20of%20available%20runner%20types%2C%20refer%20to%20%3C%2FSPAN%3E%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20https%3A%2F%2Fhelp.github.com%2Fen%2Factions%2Freference%2Fworkflow-syntax-for-github-actions%23jobsjob_idruns-on%3C%2FSPAN%3E%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20env%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20Solution_Name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EContosoApp.sln%3C%2FSPAN%3E%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20Wap_Project_Directory%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EContosoApp.Package%3C%2FSPAN%3E%20%20%20%20%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20Wap_Project_Path%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EContosoApp.Package%5CContosoApp.Package.wapproj%3C%2FSPAN%3E%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20steps%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ECheckout%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eactions%2Fcheckout%40v2%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20with%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20fetch-depth%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-number%22%3E0%3C%2FSPAN%3E%0A%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Add%20%20MSBuild%20to%20the%20PATH%3A%20https%3A%2F%2Fgithub.com%2Fmicrosoft%2Fsetup-msbuild%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ESetup%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EMSBuild.exe%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emicrosoft%2Fsetup-msbuild%402008f912f56e61277eefaac6d1888b750582aa16%3C%2FSPAN%3E%0A%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Restore%20the%20application%20to%20populate%20the%20obj%20folder%20with%20RuntimeIdentifiers%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ERestore%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ethe%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eapplication%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20run%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emsbuild%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24env%3ASolution_Name%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Ft%3ARestore%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AConfiguration%3D%24env%3AConfiguration%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20env%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20Configuration%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ematrix.configuration%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%0A%20%20%20%20%20%20%20%20%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Decode%20the%20base%2064%20encoded%20pfx%20and%20save%20the%20Signing_Certificate%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EDecode%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ethe%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Epfx%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20run%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7C%0A%20%20%20%20%20%20%20%20%24pfx_cert_byte%20%3D%20%5BSystem.Convert%5D%3A%3AFromBase64String(%22%24%3CSPAN%20class%3D%22hljs-template-variable%22%3E%7B%7B%20secrets.Base64_Encoded_Pfx%20%7D%7D%3C%2FSPAN%3E%22)%0A%20%20%20%20%20%20%20%20%24certificatePath%20%3D%20Join-Path%20-Path%20%24env%3AWap_Project_Directory%20-ChildPath%20GitHubActionsWorkflow.pfx%0A%20%20%20%20%20%20%20%20%5BIO.File%5D%3A%3AWriteAllBytes(%22%24certificatePath%22%2C%20%24pfx_cert_byte)%0A%20%20%0A%20%20%20%20%23%20Create%20the%20app%20package%20by%20building%20and%20packaging%20the%20Windows%20Application%20Packaging%20project%0A%3C%2FSPAN%3E%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ECreate%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ethe%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eapp%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Epackage%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20run%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Emsbuild%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24env%3AWap_Project_Path%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AConfiguration%3D%24env%3AConfiguration%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AUapAppxPackageBuildMode%3D%24env%3AAppx_Package_Build_Mode%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AAppxBundle%3D%24env%3AAppx_Bundle%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AGenerateAppInstallerFile%3D%24env%3AGenerate_AppInstaller%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3AAppInstallerUri%3D%24env%3AAppInstaller_Url%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3APackageCertificateKeyFile%3DGitHubActionsWorkflow.pfx%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%2Fp%3APackageCertificatePassword%3D%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Esecrets.Pfx_Key%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20env%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20Appx_Bundle%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EAlways%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20Appx_Bundle_Platforms%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ex86%7Cx64%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20Appx_Package_Build_Mode%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ESideloadOnly%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20Configuration%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ematrix.configuration%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20Generate_AppInstaller%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-literal%22%3Etrue%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20AppInstaller_Url%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-attr%22%3Ehttps%3A%2F%2Fcalm-desert-05f99c503.azurestaticapps.net%3C%2FSPAN%3E%0A%20%20%20%20%20%20%20%20%20%20%20%20%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Remove%20the%20pfx%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ERemove%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ethe%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Epfx%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20run%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3ERemove-Item%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-bullet%22%3E-path%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24env%3AWap_Project_Directory%5CGitHubActionsWorkflow.pfx%3C%2FSPAN%3E%0A%0A%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Upload%20the%20MSIX%20package%3A%20https%3A%2F%2Fgithub.com%2Fmarketplace%2Factions%2Fupload-artifact%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EUpload%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ebuild%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eartifacts%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eactions%2Fupload-artifact%40v1%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20with%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EMSIX%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EPackage%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20path%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eenv.Wap_Project_Directory%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%5CAppPackages%3C%2FSPAN%3E%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3EThis%20is%20enough%20to%20get%20a%20ready%20to%20be%20deployed%20MSIX%20package.%20If%20you%20commit%20any%20change%20to%20the%20repository%20which%20hosts%20your%20desktop%20app%2C%20the%20process%20should%20complete%20without%20errors%20and%2C%20in%20the%20end%2C%20you%20should%20have%20an%20artifact%20folder%20which%20contains%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3EYour%20signed%20MSIX%20package%3C%2FLI%3E%0A%3CLI%3EThe%20file%20with%20.appinstaller%20extension%20required%20to%20install%20the%20package%20from%20a%20website%20or%20network%20share%3C%2FLI%3E%0A%3CLI%3EA%20web%20page%20(index.html)%20which%20contains%20the%20link%20to%20trigger%20the%20installation%20of%20the%20MSIX%20package%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CH3%20id%3D%22deploy-on-azure-static-web-app%22%20id%3D%22toc-hId--1762697643%22%20id%3D%22toc-hId--1762697642%22%3EDeploy%20on%20Azure%20Static%20Web%20App%3C%2FH3%3E%0A%3CP%3ENow%20it's%20time%20to%20go%20back%20to%20the%20original%20workflow%20file%20that%20was%20created%20when%20we%20have%20created%20the%20Azure%20Static%20Web%20App%20and%20that%20we%20have%20copied%20before%20starting%20making%20changes.%20We%20need%2C%20in%20fact%2C%20to%20leverage%20the%20task%20that%20will%20take%20care%20of%20deploying%20on%20the%20Web%20App%20the%20artifact%20we%20have%20just%20created.%20However%2C%20in%20order%20to%20do%20this%2C%20we're%20going%20to%20create%20a%20different%20job.%20Its%20purpose%20will%20be%20to%20download%20the%20artifact%20we%20have%20generated%20and%20to%20deploy%20it.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWhy%20using%20a%20separate%20job%3F%20The%20first%20reason%20is%20more%20%22philosophical%22.%20The%20deployment%20is%20a%20different%20step%20compared%20to%20the%20build%20process.%20Azure%20DevOps%20does%20a%20great%20job%20in%20helping%20to%20keep%20the%20two%20phases%20separated%2C%20by%20providing%20release%20pipelines%20to%20handle%20the%20release%20management%20story.%20GitHub%20doesn't%20support%20this%20approach%20but%2C%20still%2C%20a%20multi-stage%20pipeline%20can%20help%20us%20to%20better%20split%20the%20two%20phases.%20The%20second%20reason%20is%20more%20practical.%20The%20action%20which%20performs%20the%20deployment%20to%20Azure%20Static%20Web%20App%20(the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3EAzure%2Fstatic-web-apps-deploy%40v0.0.1-preview%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eone)%20works%20only%20on%20Linux%2C%20while%20the%20build%20process%20we%20have%20executed%20so%20far%20must%20run%20on%20Windows.%20By%20using%20multiple%20jobs%2C%20we%20can%20use%20different%20environments%3A%20the%20build%20job%20will%20continue%20to%20run%20on%20a%20Windows%20hosted%20agent%2C%20while%20we're%20going%20to%20run%20the%20deployment%20job%20on%20a%20Linux%20machine.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ELet's%20go%20and%20add%20the%20second%20job%20after%20the%20first%20one%20we%20have%20previously%20configured%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22language-yaml%20hljs%22%3E%3CSPAN%20class%3D%22hljs-attr%22%3Edeploy%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20needs%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%5Bbuild%5D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20runs-on%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eubuntu-latest%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EDeploy%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EJob%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20steps%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EDownload%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EPackage%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eartifact%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Eactions%2Fdownload-artifact%40master%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20with%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EMSIX%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EPackage%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20path%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EMSIX%3C%2FSPAN%3E%20%0A%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20-%20name%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EBuild%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EAnd%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EDeploy%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20id%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Ebuilddeploy%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20uses%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3EAzure%2Fstatic-web-apps-deploy%40v0.0.1-preview%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20with%3A%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20azure_static_web_apps_api_token%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Esecrets.AZURE_STATIC_WEB_APPS_API_TOKEN_CALM_DESERT_05F99C503%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20repo_token%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%24%7B%7B%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3Esecrets.GITHUB_TOKEN%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%7D%7D%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20Used%20for%20Github%20integrations%20(i.e.%20PR%20comments)%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20action%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%22upload%22%3C%2FSPAN%3E%0A%20%20%20%20%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%23%23%23%23%23%20Repository%2FBuild%20Configurations%20-%20These%20values%20can%20be%20configured%20to%20match%20you%20app%20requirements.%20%23%23%23%23%23%23%3C%2FSPAN%3E%0A%20%20%20%20%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20For%20more%20information%20regarding%20Static%20Web%20App%20workflow%20configurations%2C%20please%20visit%3A%20https%3A%2F%2Faka.ms%2Fswaworkflowconfig%3C%2FSPAN%3E%0A%3CSPAN%20class%3D%22hljs-attr%22%3E%20%20%20%20%20%20%20%20app_location%3A%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-string%22%3E%22MSIX%22%3C%2FSPAN%3E%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%20App%20source%20code%20path%3C%2FSPAN%3E%0A%20%20%20%20%20%20%20%20%3CSPAN%20class%3D%22hljs-comment%22%3E%23%23%23%23%23%23%20End%20of%20Repository%2FBuild%20Configurations%20%23%23%23%23%23%23%3C%2FSPAN%3E%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3EThis%20job%20contains%20only%20two%20tasks%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%0A%3CP%3EThe%20first%20one%20uses%20the%20action%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Eactions%2Fdownload-artifact%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eto%20download%20on%20the%20machine%20the%20artifact%20we%20have%20just%20created%20in%20the%20build%20job.%20The%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Ename%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eproperty%20must%20match%20the%20value%20of%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Ename%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eproperty%20we%20have%20set%20in%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Eactions%2Fupload-artifact%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Etask%20of%20the%20build%20job.%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%0A%3CP%3EThe%20second%20one%20is%20the%20task%20we%20have%20previously%20copied%20from%20the%20original%20workflow%20file%2C%20which%20takes%20care%20to%20do%20the%20deployment%20to%20the%20Azure%20Static%20Web%20App.%20Compared%20to%20the%20original%20task%2C%20we%20have%20to%20make%20a%20couple%20of%20changes%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3EThe%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Eapp_location%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eparameter%20must%20be%20set%20with%20the%20name%20of%20the%20folder%20that%20contains%20the%20artifact%20we%20need%20to%20deploy.%20In%20our%20case%2C%20it's%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3EMSIX%3C%2FCODE%3E%2C%20which%20is%20the%20value%20we%20have%20set%20as%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Epath%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Ein%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Eactions%2Fdownload-artifact%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Etask.%3C%2FLI%3E%0A%3CLI%3EWe%20can%20remove%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Eapi_location%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eand%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Eapp_artifact_location%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eproperties%2C%20since%20we%20aren't%20deploying%20a%20full%20static%20web%20app.%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3EAs%20you%20can%20notice%2C%20we%20have%20configured%20the%20job%20to%20run%20on%20Linux%20(%3CCODE%3Eruns-on%3A%20ubuntu-latest%3C%2FCODE%3E)%20and%20we%20have%20used%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Eneeds%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eparameter%20to%20specify%20that%20this%20task%20must%20run%20only%20after%20the%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CCODE%3Ebuild%3C%2FCODE%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eone%20has%20been%20completed.%20Without%20this%20option%2C%20GitHub%20would%20try%20to%20run%20both%20jobs%20in%20parallel.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThat's%20it!%20Now%20try%20to%20commit%20any%20change%20to%20the%20code%20to%20trigger%20the%20execution%20of%20the%20workflow.%20If%20you%20did%20everything%20in%20the%20correct%20way%2C%20once%20the%20workflow%20is%20completed%2C%20you%20should%20be%20able%20to%20open%20your%20browser%20on%20the%20URL%20assigned%20to%20your%20Azure%20Static%20Web%20App%20and%20see%20the%20web%20page%20generated%20by%20Visual%20Studio%20to%20trigger%20the%20installation%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22ContosoApp.png%22%20style%3D%22width%3A%20713px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F197918i1D1C11D919BDDDE7%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22ContosoApp.png%22%20alt%3D%22ContosoApp.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%3EBy%20clicking%20on%20the%26nbsp%3B%3C%2FSPAN%3E%3CSTRONG%3EGet%20the%20app%3C%2FSTRONG%3E%3CSPAN%3E%26nbsp%3Bbutton%2C%20you%20will%20trigger%20the%20process%20to%20start%20the%20installation%3A%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22ContosoAppInstallation.png%22%20style%3D%22width%3A%20650px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F197919i4B5D953FC21EBED8%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22ContosoAppInstallation.png%22%20alt%3D%22ContosoAppInstallation.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CH3%20id%3D%22wrapping-up%22%20id%3D%22toc-hId-724815190%22%20id%3D%22toc-hId-724815191%22%3EWrapping%20up%3C%2FH3%3E%0A%3CP%3EIn%20this%20blog%20post%20we%20have%20seen%20how%20to%20use%20the%20recently%20announced%20Azure%20Static%20Web%20App%20service%20to%20host%20our%20MSIX%20packages%20and%20enable%20an%20easy%20installation%20process%20of%20our%20desktop%20apps%20through%20a%20website.%20By%20tweaking%20the%20project%20we%20can%20also%20enable%20automatic%20updates%3A%20we%20just%20need%20to%20configure%20the%20AppInstaller%20file%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fwindows%2Fmsix%2Fapp-installer%2Fupdate-settings%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Eto%20support%20automatic%20updates%3C%2FA%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eand%20use%20a%20tool%20like%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fdotnet%2FNerdbank.GitVersioning%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3ENerdbank.GitVersioning%3C%2FA%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eto%20handle%20the%20versioning%20of%20the%20MSIX%20packages%2C%20so%20that%20we're%20sure%20that%20every%20new%20generated%20package%20will%20have%20a%20higher%20version%20number.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20sample%20project%20used%20in%20this%20blog%20post%20(including%20the%20GitHub%20workflow)%20is%20available%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fqmatteoq%2FContosoApp%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Ehere%3C%2FA%3E.%20If%2C%20instead%2C%20you%20want%20to%20see%20a%20more%20advanced%20approach%2C%20you%20can%20take%20a%20look%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fqmatteoq%2FContosoExpenses-GitHub%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Eat%20another%20project%20from%20me%3C%2FA%3E.%20This%20second%20repository%20contains%20a%20more%20complete%20workflow%2C%20which%20includes%20versioning%20management%20and%20signing%20using%20Azure%20Key%20Vault.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EA%20special%20thanks%20to%20%3CA%20href%3D%22https%3A%2F%2Fwithinrafael.com%2F%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3ERafael%20Rivera%3C%2FA%3E%20and%20%3CA%20href%3D%22https%3A%2F%2Fwww.linkedin.com%2Fin%2Fmitchell-webster-a01656a0%2F%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3EMitchell%20Webster%3C%2FA%3E%20for%20the%20help%20in%20troubleshooting%20and%20fixing%20%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2FAzure%2Fstatic-web-apps%2Fissues%2F26%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Ea%20series%20of%20issues%3C%2FA%3E%20that%20were%20preventing%20Azure%20Static%20Web%20Apps%20to%20work%20properly%20with%20MSIX%20deployment.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EHappy%20deployment!%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-TEASER%20id%3D%22lingo-teaser-1453991%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fstatic-web-apps%2Foverview%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%20target%3D%22_blank%22%3EAzure%20Static%20Web%20Apps%3C%2FA%3E%3CSPAN%3E%26nbsp%3Bis%20a%20new%20Azure%20service%20launched%20in%20Preview%20at%20Build%202020%2C%20which%20offers%20an%20app%20service%20dedicated%20to%20static%20websites.%26nbsp%3BLet's%20see%20how%20we%20can%20use%20an%20Azure%20Static%20Web%20App%20to%20host%20our%20MSIX%20package%2C%20which%20will%20be%20automatically%20built%20and%20deployed%20by%20a%20GitHub%20Action.%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-TEASER%3E
Microsoft

Azure Static Web Apps is a new Azure service launched in Preview at Build 2020, which offers an app service dedicated to static websites. You could say "why is it so special"? In the end, hosting a static website is relatively simple, since there isn't any server-side component: no databases, no ASP.NET Core or PHP or Node runtime, just pure HTML, CSS and JavaScript. Azure Static Web Apps is more than just hosting for static content: thanks to its tight connection to GitHub, it supports creating automated pipelines (through GitHub Actions) which are able to automatically build and deploy full stack web apps.

 

This service is a great companion for frameworks like Gatsby or Hugo, which are able to generate static pages as part of the build process. Let's say that you're using Hugo to host your personal blog. Thanks to Azure Static Web App, you can just simply commit to your GitHub repository a markdown file with your latest post to trigger the execution of a GitHub Action, which will build it as a static page.

And if you need to add a server-side component (for example, hosting a REST API), the Azure Static Web App service supports the deployment of serverless APIs based on Azure Functions.

 

However, as you know, in my everyday job I'm focused on the development and the deployment of Windows desktop applications. And, as you probably know if you follow this blog or if you have read my book about MSIX, I'm a big fan of MSIX and the App Installer technology, which enables to easily have a solid CI/CD story for Windows applications. Thanks to them, in fact, we can enable features like automatic updates, critical updates, differential updates, etc. And guess what? All you need is a static website that can host your MSIX package, plus the AppInstaller file.

 

I guess now you know where I'm headed to =) Let's see how we can use an Azure Static Web App to host our MSIX package, which will be automatically built and deployed by a GitHub Action.

 

Set up the Azure Static Web App

As first step, let's create our Azure Static Web App. Login to the Azure portal with your account and click on Create a resource. Start a search using the static keyword. One of the results will be Static Web App (Preview), as in the following image:

 

NewStaticWebApp.png

 

Click on it and choose Create to start the process:

 

CreateNewApp.png

 

The first information you have to provide are the subscription, the resource group, the name of the app and the region. The only available SKU, for the moment, is the Free one, since the service is in preview. Currently this service works only with GitHub, since it doesn't use it just to connect to the repository, but it's going to create the GitHub Action needed to compile and deploy the project for us. As such, the next required step is to click on Sign in with GitHub to complete the login process with your GitHub account. Once you are logged in, you will have the opportunity to choose an organization, a repository and a branch from the ones have on GitHub:

 

GitHubSetup.png

 

For our scenario we're going to choose a repository which contains a .NET Desktop application packaged with the Windows Application Packaging Project. The one I'm using for this blog post is available at https://github.com/qmatteoq/ContosoApp. It's just a plain WPF application based on .NET Core 3.1.

Once you have completed the configuration, press Review + create, followed by Create in the review page. Once the deployment has been completed, you will notice a few changes in your GitHub repository:

 

  • There will be a new folder, called github/workflows with a YAML file inside. That's our GitHub workflow. We can see it also by clicking on the Actions tab in the repository:

GitHubAction.png

The workflow is called Azure Static Web Apps CI/CD and it will be executed immediately. However, it will fail, since our repository contains a desktop application and the default workflow isn't tailored for this scenario. Don't worry, we're going to fix that!

 

  • If you go to the Settings section of the repository and you move to the Secrets tab, you will find out that Azure Static Web App has added a new secret for you:

Secret.png

This secret contains the API token which is required by the GitHub Action to connect to the Azure Static Web App instance we have created, in order to perform the deployment.

 

Customize the workflow

Let's take a look at the workflow that the Azure Static Web App has created for us:

 

name: Azure Static Web Apps CI/CD

on:
  push:
    branches:
      - master
  pull_request:
    types: [opened, synchronize, reopened, closed]
    branches:
      - master

jobs:
  build_and_deploy_job:
    if: github.event_name == 'push' || (github.event_name == 'pull_request' && github.event.action != 'closed')
    runs-on: ubuntu-latest
    name: Build and Deploy Job
    steps:
      - uses: actions/checkout@v2
        with:
          submodules: true
      - name: Build And Deploy
        id: builddeploy
        uses: Azure/static-web-apps-deploy@v0.0.1-preview
        with:
          azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN_CALM_DESERT_05F99C503 }}
          repo_token: ${{ secrets.GITHUB_TOKEN }} # Used for Github integrations (i.e. PR comments)
          action: "upload"
          ###### Repository/Build Configurations - These values can be configured to match you app requirements. ######
          # For more information regarding Static Web App workflow configurations, please visit: https://aka.ms/swaworkflowconfig
          app_location: "/" # App source code path
          api_location: "api" # Api source code path - optional
          app_artifact_location: "" # Built app content directory - optional
          ###### End of Repository/Build Configurations ######

  close_pull_request_job:
    if: github.event_name == 'pull_request' && github.event.action == 'closed'
    runs-on: ubuntu-latest
    name: Close Pull Request Job
    steps:
      - name: Close Pull Request
        id: closepullrequest
        uses: Azure/static-web-apps-deploy@v0.0.1-preview
        with:
          azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN_CALM_DESERT_05F99C503 }}
          action: "close"

The workflow contains two distinct jobs:

  • build_and_deploy_job is triggered whenever you submit a new Pull Request to the repository. The goal of this job is to build the updated website included in the Pull Request and to deploy it in a staging environment, so that you can test that everything is working as expected.
  • close_pull_request_job is triggered whenever you close a Pull Request. This means that the you have validated that the Pull Request is good and, as such, the staging environment can be deleted because the new version of the website can be safely pushed to production.

As you can imagine, however, for our scenario this isn't really applicable, since we aren't really deploying a website, but a desktop application to be deployed. As such, we're going to basically delete everything from this workflow file, except for the Build and deploy task, which is based on the action called Azure/static-web-apps-deploy@v0.0.1-preview. We're going to use this one to publish the output of the Visual Studio compilation: the MSIX package, the AppInstaller file and the web page to trigger the installation.

 

To customize the workflow, we're going to take inspiration from the template created by .NET Team, which is a great starting point when you want to build desktop .NET Core applications on GitHub. This template perfectly fits my scenario: I have a WPF application based on .NET Core and a Windows Application Packaging Project to generate the MSIX package.

 

Let's start by creating a copy of the existing workflow file. We're going to need it later. Now open on GitHub the workflow file (in my case, it's https://github.com/qmatteoq/ContosoApp/blob/master/.github/workflows/azure-static-web-apps-calm-dese...) and click on the edit icon (the small pencil in the toolbar):

 

EditFile.png

 

When you do this, GitHub will propose you a special edit interface tailored for workflows. Thanks a to a panel on the right, you'll be able to easily browse the Actions marketplace and integrate tasks in the workflow.

 

EditGitHubAction.png

 

For the moment, let's delete everything (except for the first line which defines the name) and replace the content with the one from the .NET Desktop workflow. This is how your workflow should look like:

 

name: Azure Static Web Apps CI/CD

on:
  push:
    branches: [ master ]
  pull_request:
    branches: [ master ]

jobs:

  build:

    strategy:
      matrix:
        configuration: [Debug, Release]

    runs-on: windows-latest  # For a list of available runner types, refer to 
                             # https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idruns-on

    env:
      Solution_Name: your-solution-name                         # Replace with your solution name, i.e. MyWpfApp.sln.
      Test_Project_Path: your-test-project-path                 # Replace with the path to your test project, i.e. MyWpfApp.Tests\MyWpfApp.Tests.csproj.
      Wap_Project_Directory: your-wap-project-directory-name    # Replace with the Wap project directory relative to the solution, i.e. MyWpfApp.Package.
      Wap_Project_Path: your-wap-project-path                   # Replace with the path to your Wap project, i.e. MyWpf.App.Package\MyWpfApp.Package.wapproj.

    steps:
    - name: Checkout
      uses: actions/checkout@v2
      with:
        fetch-depth: 0

    # Install the .NET Core workload
    - name: Install .NET Core
      uses: actions/setup-dotnet@v1
      with:
        dotnet-version: 3.1.101

    # Add  MSBuild to the PATH: https://github.com/microsoft/setup-msbuild
    - name: Setup MSBuild.exe
      uses: microsoft/setup-msbuild@2008f912f56e61277eefaac6d1888b750582aa16

    # Execute all unit tests in the solution
    - name: Execute unit tests
      run: dotnet test

    # Restore the application to populate the obj folder with RuntimeIdentifiers
    - name: Restore the application
      run: msbuild $env:Solution_Name /t:Restore /p:Configuration=$env:Configuration
      env:
        Configuration: ${{ matrix.configuration }}

    # Decode the base 64 encoded pfx and save the Signing_Certificate
    - name: Decode the pfx
      run: |
        $pfx_cert_byte = [System.Convert]::FromBase64String("${{ secrets.Base64_Encoded_Pfx }}")
        $certificatePath = Join-Path -Path $env:Wap_Project_Directory -ChildPath GitHubActionsWorkflow.pfx
        [IO.File]::WriteAllBytes("$certificatePath", $pfx_cert_byte)

    # Create the app package by building and packaging the Windows Application Packaging project
    - name: Create the app package
      run: msbuild $env:Wap_Project_Path /p:Configuration=$env:Configuration /p:UapAppxPackageBuildMode=$env:Appx_Package_Build_Mode /p:AppxBundle=$env:Appx_Bundle /p:PackageCertificateKeyFile=GitHubActionsWorkflow.pfx /p:PackageCertificatePassword=${{ secrets.Pfx_Key }}
      env:
        Appx_Bundle: Always
        Appx_Bundle_Platforms: x86|x64
        Appx_Package_Build_Mode: StoreUpload
        Configuration: ${{ matrix.configuration }}

    # Remove the pfx
    - name: Remove the pfx
      run: Remove-Item -path $env:Wap_Project_Directory\$env:Signing_Certificate

    # Upload the MSIX package: https://github.com/marketplace/actions/upload-artifact
    - name: Upload build artifacts
      uses: actions/upload-artifact@v1
      with:
        name: MSIX Package
        path: ${{ env.Wap_Project_Directory }}\AppPackages

Let's go and customize a few things. First, you'll need to customize the environment variables defined at the top to point to your solutions and project. You'll have to setup:

 

  • Solution_Name with the relative path of the solution file
  • Wap_Project_Directory with the relative path of the folder which contains the Windows Application Packaging Project
  • Wap_Project_Path with the full path of Windows Application Packaging Project file

Optionally, you can also use the Test_Project_Path to configure the path of the project which contains your unit tests. In my case, since it's a sample project, I don't have one, so I simply removed that variable. This is how my environment configuration looks like:

 

env:
  Solution_Name: ContosoApp.sln                
  Wap_Project_Directory: ContosoApp.Package    
  Wap_Project_Path: ContosoApp.Package\ContosoApp.Package.wapproj

Second, for our scenario, we don't really need to build the application both in Debug and Release mode. We just want to have, as output, a single release MSIX package, so that we can deploy it on our website. As such, remove from the configuration matrix the Debug entry:

 

strategy:
  matrix:
    configuration: [Release]

As next step, I'm going to customize some of the available tasks:

  • Execute unit tests isn't needed for my sample application, since I don't have unit tests. As such, I'm going to delete this one.

  • Build. Since we're going to use the AppInstaller technology to distribute the package using our Azure Static Web App, we need to tweak a bit the various parameters.

    • The first one is the Appx_Package_Build_Mode parameter, which by default is set to StoreUpload, which is the needed when you want to publish the application on the Microsoft Store. In this case we're using manual distribution, so we need to change it to SideloadOnly.
    • We need to add the /p:GenerateAppInstallerFile parameter and set it to true, in order to generate the .appinstaller file and the web page as part of the process.
    • We need to add the /p:AppInstallerUri parameter and set it to the URL that has been assigned to our Azure Static Web App. You can find this URL in the Azure portal:

AzureAppUrl.png

 

This is how the task looks like after the changes:

 

# Create the app package by building and packaging the Windows Application Packaging project
- name: Create the app package
  run: msbuild $env:Wap_Project_Path /p:Configuration=$env:Configuration /p:UapAppxPackageBuildMode=$env:Appx_Package_Build_Mode /p:AppxBundle=$env:Appx_Bundle /p:GenerateAppInstallerFile=$env:Generate_AppInstaller /p:AppInstallerUri=$env:AppInstaller_Url /p:PackageCertificateKeyFile=GitHubActionsWorkflow.pfx /p:PackageCertificatePassword=${{ secrets.Pfx_Key }}
  env:
    Appx_Bundle: Always
    Appx_Bundle_Platforms: x86|x64
    Appx_Package_Build_Mode: SideloadOnly
    Configuration: ${{ matrix.configuration }}
    Generate_AppInstaller: true
    AppInstaller_Url: https://calm-desert-05f99c503.azurestaticapps.net

Setting up the signing

As I have discussed multiple times in this blog, signing is a critical aspect of MSIX packaging. If you don't sign a MSIX package with a trusted certificate, the user will never be able to install it. At the same time, you must be very careful in how you enable signing as part of a CI/CD pipeline. If you expose your private certificate, someone might be able to steal it and use your identity to sign malicious applications. There are multiple approaches to sign MSIX packages in the right way as part of a CI/CD pipeline. The approach used by the workflow template is to ask to the developer to encode the PFX into a base64 string and store it as a secret. Then the workflow includes a PowerShell script which takes care of decoding the secret back into a PFX, so that it can be used as part of the Visual Studio build to do the signing.

 

The main reasoning of using this approach on GitHub is that, unlike Azure DevOps, the platform doesn't have the concept of Secure Files, which is often used in scenarios like this one.

The GitHub Action workflow already contains everything you need to sign the package. The only missing step is to create the secrets to store the various required information.

 

  1. Open a PowerShell terminal in the folder in which you keep your PFX certificate.

  2. Run the following script:

    $pfx_cert = Get-Content '.\SigningCertificate.pfx' -Encoding Byte
    [System.Convert]::ToBase64String($pfx_cert) | Out-File 'SigningCertificate_Encoded.txt'
    
  3. At the end of the process you will find, in the same folder, a text file called SigningCertificate_Encoded.txt, which contains the certificate encoded as a base64 string. Open the text file and copy the whole content.

  4. Now go to your repository on GitHub, choose Settings → Secrets and create a new secret.

  5. Call the secret Base64_Encoded_Pfx and, as value, paste the encoded base64 string you have just copied.

  6. Now create a new secret and call it Pfx_Key. As value, type the password for the signing certificate.

That's it. Another and safer alternative to this approach is to leverage Azure Key Vault to store your certificate and the Azure SignTool utility to do the actual signing as part of the pipeline. You can find all the details about this approach, including how to use it in a GitHub Action workflow, in a recent blog post I wrote.

 

Reviewing the pipeline

We have finished the work on the build pipeline. This is how it should look like after the changes:

 

name: Azure Static Web Apps CI/CD

on:
  push:
    branches: [ master ]
  pull_request:
    branches: [ master ]

jobs:

  build:

    strategy:
      matrix:
        configuration: [Release]

    runs-on: windows-latest  # For a list of available runner types, refer to 
                             # https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idruns-on

    env:
      Solution_Name: ContosoApp.sln                
      Wap_Project_Directory: ContosoApp.Package    
      Wap_Project_Path: ContosoApp.Package\ContosoApp.Package.wapproj                  

    steps:
    - name: Checkout
      uses: actions/checkout@v2
      with:
        fetch-depth: 0

    # Add  MSBuild to the PATH: https://github.com/microsoft/setup-msbuild
    - name: Setup MSBuild.exe
      uses: microsoft/setup-msbuild@2008f912f56e61277eefaac6d1888b750582aa16

    # Restore the application to populate the obj folder with RuntimeIdentifiers
    - name: Restore the application
      run: msbuild $env:Solution_Name /t:Restore /p:Configuration=$env:Configuration
      env:
        Configuration: ${{ matrix.configuration }}
        
    # Decode the base 64 encoded pfx and save the Signing_Certificate
    - name: Decode the pfx
      run: |
        $pfx_cert_byte = [System.Convert]::FromBase64String("${{ secrets.Base64_Encoded_Pfx }}")
        $certificatePath = Join-Path -Path $env:Wap_Project_Directory -ChildPath GitHubActionsWorkflow.pfx
        [IO.File]::WriteAllBytes("$certificatePath", $pfx_cert_byte)
  
    # Create the app package by building and packaging the Windows Application Packaging project
    - name: Create the app package
      run: msbuild $env:Wap_Project_Path /p:Configuration=$env:Configuration /p:UapAppxPackageBuildMode=$env:Appx_Package_Build_Mode /p:AppxBundle=$env:Appx_Bundle /p:GenerateAppInstallerFile=$env:Generate_AppInstaller /p:AppInstallerUri=$env:AppInstaller_Url /p:PackageCertificateKeyFile=GitHubActionsWorkflow.pfx /p:PackageCertificatePassword=${{ secrets.Pfx_Key }}
      env:
        Appx_Bundle: Always
        Appx_Bundle_Platforms: x86|x64
        Appx_Package_Build_Mode: SideloadOnly
        Configuration: ${{ matrix.configuration }}
        Generate_AppInstaller: true
        AppInstaller_Url: https://calm-desert-05f99c503.azurestaticapps.net
            
    # Remove the pfx
    - name: Remove the pfx
      run: Remove-Item -path $env:Wap_Project_Directory\GitHubActionsWorkflow.pfx

    # Upload the MSIX package: https://github.com/marketplace/actions/upload-artifact
    - name: Upload build artifacts
      uses: actions/upload-artifact@v1
      with:
        name: MSIX Package
        path: ${{ env.Wap_Project_Directory }}\AppPackages

This is enough to get a ready to be deployed MSIX package. If you commit any change to the repository which hosts your desktop app, the process should complete without errors and, in the end, you should have an artifact folder which contains:

 

  • Your signed MSIX package
  • The file with .appinstaller extension required to install the package from a website or network share
  • A web page (index.html) which contains the link to trigger the installation of the MSIX package

Deploy on Azure Static Web App

Now it's time to go back to the original workflow file that was created when we have created the Azure Static Web App and that we have copied before starting making changes. We need, in fact, to leverage the task that will take care of deploying on the Web App the artifact we have just created. However, in order to do this, we're going to create a different job. Its purpose will be to download the artifact we have generated and to deploy it.

 

Why using a separate job? The first reason is more "philosophical". The deployment is a different step compared to the build process. Azure DevOps does a great job in helping to keep the two phases separated, by providing release pipelines to handle the release management story. GitHub doesn't support this approach but, still, a multi-stage pipeline can help us to better split the two phases. The second reason is more practical. The action which performs the deployment to Azure Static Web App (the Azure/static-web-apps-deploy@v0.0.1-preview one) works only on Linux, while the build process we have executed so far must run on Windows. By using multiple jobs, we can use different environments: the build job will continue to run on a Windows hosted agent, while we're going to run the deployment job on a Linux machine.

 

Let's go and add the second job after the first one we have previously configured:

 

deploy:
  needs: [build]
  runs-on: ubuntu-latest
  name: Deploy Job
  steps:
    - name: Download Package artifact
      uses: actions/download-artifact@master
      with:
        name: MSIX Package
        path: MSIX 

    - name: Build And Deploy
      id: builddeploy
      uses: Azure/static-web-apps-deploy@v0.0.1-preview
      with:
        azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN_CALM_DESERT_05F99C503 }}
        repo_token: ${{ secrets.GITHUB_TOKEN }} # Used for Github integrations (i.e. PR comments)
        action: "upload"
        ###### Repository/Build Configurations - These values can be configured to match you app requirements. ######
        # For more information regarding Static Web App workflow configurations, please visit: https://aka.ms/swaworkflowconfig
        app_location: "MSIX" # App source code path
        ###### End of Repository/Build Configurations ######

This job contains only two tasks:

 

  • The first one uses the action actions/download-artifact to download on the machine the artifact we have just created in the build job. The name property must match the value of the name property we have set in the actions/upload-artifact task of the build job.

  • The second one is the task we have previously copied from the original workflow file, which takes care to do the deployment to the Azure Static Web App. Compared to the original task, we have to make a couple of changes:

    • The app_location parameter must be set with the name of the folder that contains the artifact we need to deploy. In our case, it's MSIX, which is the value we have set as path in the actions/download-artifact task.
    • We can remove the api_location and app_artifact_location properties, since we aren't deploying a full static web app.

As you can notice, we have configured the job to run on Linux (runs-on: ubuntu-latest) and we have used the needs parameter to specify that this task must run only after the build one has been completed. Without this option, GitHub would try to run both jobs in parallel.

 

That's it! Now try to commit any change to the code to trigger the execution of the workflow. If you did everything in the correct way, once the workflow is completed, you should be able to open your browser on the URL assigned to your Azure Static Web App and see the web page generated by Visual Studio to trigger the installation:

 

ContosoApp.png

 

By clicking on the Get the app button, you will trigger the process to start the installation:

 

ContosoAppInstallation.png

 

Wrapping up

In this blog post we have seen how to use the recently announced Azure Static Web App service to host our MSIX packages and enable an easy installation process of our desktop apps through a website. By tweaking the project we can also enable automatic updates: we just need to configure the AppInstaller file to support automatic updates and use a tool like Nerdbank.GitVersioning to handle the versioning of the MSIX packages, so that we're sure that every new generated package will have a higher version number.

 

The sample project used in this blog post (including the GitHub workflow) is available here. If, instead, you want to see a more advanced approach, you can take a look at another project from me. This second repository contains a more complete workflow, which includes versioning management and signing using Azure Key Vault.

 

A special thanks to Rafael Rivera and Mitchell Webster for the help in troubleshooting and fixing a series of issues that were preventing Azure Static Web Apps to work properly with MSIX deployment.

 

Happy deployment!