Skip to main content
Mark Ku's Blog

Purpose

To reduce the time spent and human error on manual deployment, the deployment method for the C# API has been changed.

Deploy flow

Firstly, all deployment DLLs must be committed to ApiArtifact, which can be accessed by navigating to the Publish folder at

https://github.com/XyzCom/ApiArtifact.

Next, connect remotely to server and right-click deploy-api.ps1 on the desktop and select "Run with PowerShell". This will pull down the latest DLLs.

Select the DLLs to be deployed, and then manually click "Copy to Side " folder as shown in the image below.

Create ApiArtifact repo and git clone in deploy server ( And always upload all )

Beyond Compare selecting DLLs and right-clicking 'Copy to Side
Beyond Compare selecting DLLs and right-clicking 'Copy to Side

create powershell file ( compare-deploy-binaray.ps1 )

git pull 

$LOCAL = "C:\Workspace\ApiArtifact\bin"
$REMOTE = "C:\inetpub\Web\bin"

$env:Path = "C:\Program Files\Beyond Compare 4\" 
$filters = "/filters=-web.config"
BCompare.exe /excludefilter="web.config"  "$LOCAL" "$REMOTE" $filters

Result

Beyond Compare 4 showing Copy to Side context menu option
Beyond Compare 4 showing Copy to Side context menu option

Author

Mark Ku

10 年以上的軟體工程師,做過北美電商與 AI SaaS 訂閱收費系統。Read More

Found this useful?

The author's free tools, daily podcasts and newsletter are all here.

Mark Ku · This article is licensed under CC BY 4.0. Credit the author and link back to the original when reusing it.

Comments

Subscribe to Newsletter

Subscribe to get new posts delivered instantly — never miss a tech share.

By submitting, you agree to receive emails. You can anytime.

Popular Posts

View all
Mark Ku
··648

Oracle Cloud Always Free Tier: Linux Host and Static IP for a $0 Cloud Solution

Oracle Cloud Always Free Tier: Linux Host and Static IP for a $0 Cloud Solution
Mark Ku
··465

Say Goodbye to Postman's Fee Trap! A Hands-on Guide to Bruno, the Open-Source Git-Native API Testing Powerhouse.

Say Goodbye to Postman's Fee Trap! A Hands-on Guide to Bruno, the Open-Source Git-Native API Testing Powerhouse.
Mark Ku
··278

A Free, Open-Source, Notion-like Knowledge Base — A Complete Guide to Deploying and Backing Up Outline Wiki

A Free, Open-Source, Notion-like Knowledge Base — A Complete Guide to Deploying and Backing Up Outline Wiki
Mark Ku
··218

Building an Efficient API Management Platform: Deploying Kong Gateway from Scratch - Part 1

Building an Efficient API Management Platform: Deploying Kong Gateway from Scratch - Part 1
Mark Ku
··210

Training Your Own AI Voice: Hardware Requirements, Open-Source Model Comparison, and LoRA Fine-Tuning

Training Your Own AI Voice: Hardware Requirements, Open-Source Model Comparison, and LoRA Fine-Tuning
Mark Ku
··210

Setting Up Samba on Ubuntu to Share Folders with Windows 11

Setting Up Samba on Ubuntu to Share Folders with Windows 11