Why did Lockheed abandon the Constellation II? It’s well known that Lockheed never designed a first-generation jetliner.

Not as well known: they actually did!

The L-193 Constellation II, a quadjet with four tail-mounted engines (a configuration Lockheed would later reuse for their Jetstar business jet, and which was otherwise seen only on the VC10 and Il-62), was designed in both an airliner and a tanker version, and it actually won the U.S. Air Force’s 1955 jet tanker competition, beating out Boeing’s KC-135.  However, since the Constellation II was still a couple years away from flying, the Air Force bought a few KC-135s for use in the meantime, soon decided that they were good enough for the purpose, and eventually cancelled the Lockheed order.

At which point Lockheed abandoned the Constellation II entirely.

Which is odd, because Douglas, in pretty much the same situation at about the same time, didn’t abandon the DC-8 when the prospect for a tanker version thereof vanished in the KC-135’s jet blast; they merely redoubled their efforts with the DC-8 airliner, and went on to great success in the marketplace.  Lockheed, on the other hand, gave up on their jetliner when they lost the Air Force tanker contract.  Why?
Douglas probably already had a few commercial operators interested and close to signing orders when their tanker bid fell through. 

Lockheed didn't, and decided to not dump more money into what could very well become a black hole project that'd never pay off.

And it may well be that they decided the design wasn't feasible for commercial operators. Looking at the picture on Wikipedia, almost the entire rear third of the fuselage would have no place to fit doors or windows, making the aircraft useless for passenger operations.

And the air cargo market at the time was a lot smaller than it is today and still saturated with former military aircraft retired after the Korean war and WW2.