diff --git a/containers/oneapi/onedev.Dockerfile b/containers/oneapi/onedev.Dockerfile
index b4b5dccf50dba48d8dbc075a8f0941336354714b..143b3f6bb3984075233499d0fb17098c6283029f 100644
--- a/containers/oneapi/onedev.Dockerfile
+++ b/containers/oneapi/onedev.Dockerfile
@@ -319,15 +319,14 @@ ARG AFTERBURNER_VERSION=main
 RUN echo "" >> /etc/jug_info                                            \
  && echo " - jug_dev: ${JUG_VERSION}" >> /etc/jug_info
 
-## make entrypoint executable
-RUN chmod +x /usr/local/sbin/entrypoint.sh
+## make entrypoint executable and set up oneAPI environment
+RUN chmod +x /usr/local/sbin/entrypoint.sh                              \
+   && echo "source /opt/intel/oneapi/setvars.sh --force 2> /dev/null"   \
+   >> /etc/profile
 
 ## make sure we have the entrypoints setup correctly
 ENTRYPOINT ["/usr/local/sbin/entrypoint.sh"]
-
-## set up oneAPI environment while using login (-l) shell
-CMD ["bash", "--rcfile", "/etc/profile", "-l", "-c",                    \
-      "source /opt/intel/oneapi/setvars.sh --force 2> /dev/null"]
+CMD ["bash", "--rcfile", "/etc/profile", "-l"]
 USER 0
 WORKDIR /
 SHELL ["/usr/local/bin/eic-shell"]