Docker Image Different Azure DevOps vs Local

Expected behavior

Docker Image built using Azure DevOps (ADO) and Locally when used to create a container. The bash script should yield the same number of files that were modified.

Actual behavior

ADO is giving me all the files (132) as modified instead of comparing with the reference manifest.json in the root folder. Local Docker container gives me the correct list of 42 files that were modified.

Additional Information

This issue is narrowed down to the way Docker image is built on ADO vs Locally. How do I compare and ensure that the image produced is the same?