@sureshvarman @mgalkin as @mloubser said, the file needs to be mounted to the rasa containers. You can achieve this in the docker-compose.override.yml:
version: '3.4'
services:
rasa-production:
volumes:
- ./customNLU.py:/app/customNLU.py
rasa-worker:
volumes:
- ./customNLU.py:/app/customNLU.py