This blog contains the technical articles on different technologies along with architectural models
Chocolatey Package Manager
Get link
Facebook
X
Pinterest
Email
Other Apps
-
Chocolatey is a command-line package manager for Windows operating system based on the NuGet package manager. Chocolatey manages its own package feed; however, you can set up your own local repository for the enterprise environment to control the package's source for installation. If you are familiar with Linux or macOS environments, the Chocolatey is similar to Apt and Homebrew, respectively
Prerequisites
Windows 10 + / Windows Server 2012+
PowerShell 5.1 +
Installing Chocolatey on Windows
You can install Chocolatey by either using the PowerShell script method or downloading the offline installer. Follow the steps below to download and install Chocolatey using the online method:
Open PowerShell in Administrator Mode by right-clicking on the application and choosing Run as Administrator:
PowerShell Admin Mode
You need to update the script execution policy on your device before installing any package. Run the following command in the PowerShell terminal to allow script execution for the system:
Set-ExecutionPolicy Bypass -Scope Process
Type Y when prompted for confirmation and allow the changes:
The next command does a few different things before installing chocolatey on the system. The first part of the command checks the security settings for the system, followed by downloading and running the install.ps1 that's downloaded from the chocolatey website without any additional dialog box. The install.ps1 PowerShell file contains the instructions to install and prepare the package manager for the system.
Verify the installation using the following command while in the same terminal session:
choco --help
The output of the command will look like this, confirming the installation of chocolatey on the system:Exploring Commands and Searching Chocolatey Package
Like most other PowerShell commands and tools, Chocolatey also comes with an inbuilt search and help command to make it easier to find the packages and get help for associated commands.
You can search for packages using the list, search, or info command. All these commands are an alias for each other and display similar results. The result for a package winrar looks like this:
The output displays the list of packages that matched the search. In this case, the output only displays Winrar 6.02. However, they may be more packages depending on the package name and similar packages release from different vendors. You can optionally search for winrar and observe the difference in the output.
Another useful command to know while using Chocolatey is the info command. Unlike the search command, this command gives out detailed information about the package and lists install instructions and any accepted parameters for the installation of the package. Below is an example of the Winrar package:
The info command is very beneficial when identifying the details of what the package does and other relevant information about the package you will install.
Another common argument that you might often use when identifying any command's possible commands and arguments are the help argument. The --help, /? or -? can be used to get assistance with almost any command.
Installing Chocolatey Packages
Once you have done enough research on the package you want to install, the next step is to download and install the package. The command used to install the chocolatey package is choco installfollowed by the name of the package of choice. The install command first downloads the package from the remote repository and then installs it on the operating system as part of one command.
The output of the command choco install Winrar will look like this:
You will be prompted to confirm the action if you have not specified the auto-accept parameters in the original command. You can add -y, --yes or --confirm at the end of your command to suppress the prompt in the terminal.If you are planning to install a package but unsure about what exactly the package will do to install the application, you can add --whatif argument to the end of the statement to understand the process that will follow. Below is an example of whatif for Winrar installation:While installing a new package, you may have some old versions lying around on the system that you must update. Luckily, chocolatey has a outdated command that identifies any old packages installed on the system that can be updated. The following command list all the packages that are not using the latest version:choco outdatedIf you identify any old package that you'd like to update, chocolatey comes with upgrade a command that updates one or multiple packages behind the latest version release. If the package is not installed on the system already, the upgrade command will prompt and install the application for you.
Run the following command and see the results in action:
choco upgrade googlechrome
Uninstalling Chocolatey Packages
Since you've seen multiple ways to install Chocolatey packages, the uninstall command only takes uninstall to remove any package from the system.
Run the following command to uninstall the Winrar package install earlier:
Microsoft Office365 EWS servers have been extended to support authorization via the industry-standard OAuth 2.0 protocol. Using OAUTH protocol, user can do authentication by Microsoft Web OAuth instead of inputting user and password directly in application Microsoft / Office 365 OAuth + EWS We can use the OAuth authentication service provided by Azure Active Directory to enable our application to connect with IMAP, POP or SMTP protocols to access Exchange Online in Office 365. To use OAuth with our application we need to register application on Azure Active directory and other steps also we need to do to get the access token back. Below are the steps To use Microsoft/Office365 OAUTH in your application, you must create an application in https://portal.azure.com . Sign into the Azure portal using either a work or school account or a personal Microsoft account. If your account gives you access to more than one tenant, select your account in the top ...
Session stickiness , also known as(aka)., session persistence, is a process in which a load balancer creates an affinity between a client and a specific network server for the duration of a session, (i.e., the time a specific IP spends on a website). Using sticky sessions can help improve user experience and optimize network resource usage. With sticky sessions, a load balancer assigns an identifying attribute to a user, typically by issuing a cookie or by tracking their IP details. Then, according to the tracking ID, a load balancer can start routing all of the requests of this user to a specific server for the duration of the session This can prove very helpful, as HTTP/S is a stateless protocol that was not devised with session persistence in mind. Nevertheless, many web applications do have the need to serve personalized user data over the course of a session. Without session persistence, the web application would have to maintain this information across multiple servers, which can...
Procedural programming language is a type of computer coding language that helps a computer to perform tasks, and it's one of the languages programmers use most frequently. Procedural code instructs a computer or other device to complete a task using logical steps. Using a top-down approach, it separates data and procedures into different entities. Ex : BASIC, FORTRAN, PASCAL,C Features of Procedural Programming approach · TopDown Approach The top-down approach is a way of dividing and subdividing the procedure into a sequence of commands. As you break down the commands and get further through the sequence, the instructions become more specific. · Pre-defined Function Sometimes developers code n...
Comments
Post a Comment