Montresor wants to murder Fortunato with "impunity." He decides to lure him down below his palazzo and wall him up after chaining him to the wall in a narrow niche. He plans to lure Fortunato to his doom by claiming to have some rare and expensive wine down there in the catacombs. He would claim that he needs Fortunato's help because Fortunato has a reputation of being the premier connoisseur of wine in the city (apparently the city of Venice, although not stated in the story). One of Montresor's problems is to think of a wine that would provide a sufficient temptation for his intended victim. Montresor could not claim to have an Italian wine because such wines were too plentiful, and Fortunato must have a whole cellar full of them. Montresor could not claim to have a French wine because he is French himself and would be expected to know a great deal about such wines. He gives Fortunato two different French wines to keep him drunk. That left only Spain. Poe may have known virtually nothing about Spanish wine, but he probably knew that Amontillado sherry was the best wine the Spaniards exported.
Fortunato is not lured by the challenge to his connoisseurship or by the prospect of drinking a fine sherry. He drinks wine by the bottle, as shown in the story, and sherry is a sipping wine. What interests him is the prospect of making money. Montresor claims to have gotten a bargain on a "pipe" of Amontillado. A pipe of wine contains 126 gallons. It would be an enormous cask--if it really existed. Unlike Montresor who could only afford to buy a single cask, Fortunato is rich. He thinks he could possibly get a whole ship's cargo of Amontillado at a bargain price and sell it in small quantities at his convenience. But he has to make sure it is the real Amontillado, and he has to act quickly. Montresor tells him several times: "I have my doubts."
Both Fortunato and Montressor refer to the cask as a "pipe." A pipe is a standard unit of measurement for wines. It contains 126 gallons.* It is the enormous quantity as well as the quality of the Amontillado sherry that induces Fotunato to let himself be led such a long distance underground at night when he has a bad cold.
*Cf. The American Heritage Dictionary, Second College Edition (Houghton Mifflin Co., 1985)
according to your question the amontillado is the wine and the cask is the rack which holds the liquor or liquids..