Shaikh al-Albani rahimahullah was asked about this from a questioner who was from Boston in the U.S. He was asked:

Questioner:

If a person works in a place that sells pork, may Allah grant you honor, and he does not touch the pork nor sell it, but the store which he works in sells this pork, is this person’s earnings unlawful or lawful?

Shaikh:

What is the store oh my brother?

Questioner:

It is a store that sells food.

Shaikh:

Food from which is pork?

Questioner:

Yes.

Shaikh:

There is no intoxicant that is part of it?

Questioner:

No.

Shaikh:

There is no intoxicant?

Questioner:

No.

Shaikh:

Is there anything else prohibited there?

Questioner:

There is a machine that is used for gambling.

Shaikh :

Then it is not allowed for a Muslim to enter this place, [just] entering and exiting, let alone enter and work in it as an employee because Allah said:

فلا تقعد بعد الذكرى مع القوم الظّالمين

Then after the remembrance sit not you in the company of those people who are the Zalimun (polytheists and wrong-doers, etc.)

[6:68]

The Messenger of Allah sallalahu alayhi wa salam said:

من كان يؤمن بالله واليوم الآخر فلا يقعد على مائدة بدار فيها الخمر

And whoever believes in Allah and the Last Day, then he is not to sit at a table in which Khamr is circulated
[Graded Saheeh by al-Albani in al-Irwaa no. 1949]

It is not sufficient that a Muslim does not drink intoxicants. It is necessary that he is far away from the places of evil. So like this, this earning which this man has earned who works at that place which sells pork and where gambling is done, this earning is unlawful.

Question:

Alright, may Allah reward you with good.

[Silsilatul-Huda wan-Nur no. 347]

Translated by

Faisal Ibn Abdul Qaadir Ibn Hassan
Abu Sulaymaan

Also the Lajnah mentioned its prohibition here.