Greed? In some respects yes. But that isn't the whole answer. In the 18th century, the life of a common sailor did not have much to recommend it. Boys as young as twelve signed up for what they thought would be a life of adventure and exotic travel. Disillusionment followed pretty swiftly.
Life on board a merchant vessel was anything but fun. It was hard heavy work. Often the crew was short-handed, and if some of the crew died on the voyage, as they did from anything like malaria and yellow fever to accident, there were even less hands to work the ship. The work was dangerous. Imagine climbing to the topyard in a gale when the ship is pitching, the mast swaying almost at 160 degree angles, with only a footrope slung beneath the yard arm, and trying to cling on with no hand holds save the yard arm itself, and trying to sheet home, or tie off, a sail that is flapping in the wind! Below you, anything up to 120 ft down is the deck, or the sea. Certain death either way if you fall. On a slippery rolling deck, many were washed over the side, and a foot caught in a rope could put a man over the side also, while a rope suddenly snapping under tension could, and occasionally did, take a man's head off, or disembowel him!
The work was also hard. 'Sweating up' involved hauling on the ropes holding the sails fast to tighten them, for they worked loose. Hauling up the anchor was back-breaking work, either to turn the capstan (which was upright) or on the windlass (like a cotton-reel turned on its side). You get the picture.
The captain was an autocrat. This was his kingdom, and the crew had to do what he said. He could beat them to death, flog them, or shoot them, and there would be no recriminations at law. Some captains were kindly men. Many were not. There is an account of a young man who had a high fever and could hardly stand, yet the captain sent him to the topyard in a gale. He was too weak to hold on, and he fell to his death.
Furthermore, the profit or loss of a trip was dependent on the captain whose own salary came out of the profits, and if he owned the ship, all the profits! So he would cut back where he could. And that meant cutting back on food. Whenever any ship, naval or merchant, made a voyage they needed provisions, often in the form of hardtack (ship's biscuit) and salted meat as well as other commodities. The provisions had to be made from scratch, that is you put in your order to the necessary tradesmen, and they killed and salted the meat, and baked the biscuit. An unscrupulous captain would get 'second hand' provisions, old stuff that no-one wanted, half rancid, and expect the men to eat that. It was enough to make anyone mutiny!
The pay was lamentable. In today's equivalent, a sailor might make £3,000 a year. It was not enough to feed his family, if he had one. Worse, while waiting for a berth on a ship, a man might spend several weeks, or even months at the port, living in digs. He was paid in advance for the trip, and he had to settle his account with the landlord before he sailed, so in effect he was working for nothing. Even the 'officers', the mates and sailing masters, fared little better.
In the eighteenth century slavery was at its zenith. Ships would work the so-called 'golden triangle'. Leaving England laden with iron and other goods, they travelled to the West African coast where they traded the iron and so on for slaves, ivory and gold dust, then on to the Caribbean to offload the slaves, ivory and gold for sugar and tobacco, then back to England.
Often a ship would spend three months picking up the slaves from different ports along the African coast. Because the different tribes spoke different languages, they could not communicate with each other, and thus could not mutiny. Well, that was the theory. The sailors were the ones who had to load the slaves into tiers in the hold, feed them, exercise them (if the captain permitted) and clean out the hold after them. The stench in the hold was so strong it would make hardened sailors retch. They often could smell the slave ship before they could see it! The conditions for the slaves were so bad that another part of the sailor's job was to help throw the bodies overboard.
The sailors loathed working slavers, but if you were working on merchant vessels at that time slavery was usually part and parcel of the job.
So why did men sign on the merchant ships in the first place?
The answer is, there was nothing else for them. During the War of the Spanish Succession, which ended in 1713 with the treaty of Utrecht, the British navy had press-ganged thousands of men for their warships. With the treaty, however, all these men were redundant. They had nothing to go back to. So they went to sea as merchant seamen. It was all they knew how to do.
When a pirate ship attacked, raising the black flag with its threat: Yield and we give quarter; fight and we spare none! the crew surrendered immediately, even if the captain wanted to resist! The pirates plundered the ship, and then offered to sign up anyone who would like to 'go on the account'.
And most did like. They formed an orderly queue to sign the pirates' articles.