Hosting on Ubuntu Linux 20.04

Case Details

24th March 2022

Update .Net 6.0 Worker Service on Ubuntu Linux 20.04

We suppose you did some changes in your Current .Net 6.0 Worker Service (which we install in Case Study of Install .Net 6.0 Worker Service on Ubuntu Linux 20.04) and now wants to publish those changes on Ubuntu Linux and reflect those changes on the service.

1. Publish your changes to your local folder

Update-.Net-6.0-Worker-Service

Publish files

Update-.Net-6.0-Worker-Service

2. Copying Service Changes to Linux Server

In this step, we are going to copy that folder to Linux Virtual Machine for doing that we are going to use WinSCP. URL to Download WinSCP: – https: //winscp.net/eng/index.php

Update-.Net-6.0-Worker-Service

3. Check the status of the service

sudo systemctl status workerservice

And service is up and running.

Update-.Net-6.0-Worker-Service

4. Stop the running service

sudo systemctl stop workerservice

And you can again check the service status to confirm.

sudo systemctl status workerservice

Update-.Net-6.0-Worker-Service

5. Copy files to the /opt/workerservice.

sudo cp -r /home/devadmin/workerservice/ /opt/

cp -r command

Option ‘r’ with the copy command can be used to copy a directory including all its content from a source directory to the destination directory. https: //www.javatpoint.com/linux-cp-r

6. Reload daemon configs to pick up the new file.

This will pick up the new files and allow you to start the service.

sudo systemctl daemon-reload

7. Start the service

sudo systemctl start workerservice

Project Details
  • Technology: .Net 6.0
  • Database: MS SQL
  • Platform: Linux Ubuntu 20.04

Related Case Studies