anchor.diff:      echo >> /etc/jupyterhub/jupyterhub_config.py && \
       echo "c.Spawner.cmd = ['/tmp/anaconda3/bin/jupyter-labhub']" >> /etc/jupyterhub/jupyterhub_config.py && \
       echo >> /etc/jupyterhub/jupyterhub_config.py && \
  -    echo '{"argv": ["/usr/bin/R", "--slave", "-e", "IRkernel::main()", "--args", "{connection_file}"], "display_name":"R", "language":"R"}' > /tmp/anaconda3/share/jupyter/kernels/ir/kernel.json
  +    echo '{"argv": ["/tmp/anaconda3/bin/R", "--slave", "-e", "IRkernel::main()", "--args", "{connection_file}"], "display_name":"R", "language":"R"}' > /tmp/anaconda3/share/jupyter/kernels/ir/kernel.json
   
   RUN source /etc/profile && \
       echo "Install bash kernel" && \
  
positive.code:     rstudio-server verify-installation && \
      systemctl enable rstudio-server.service && \
      yum clean all && \
      rm -rf /var/cache/yum    
  
  RUN echo "Install Jupyter(hub/labs) and dependencies" && \
      source /etc/profile && \
  
negative.code: 
  RUN source /etc/profile && \
      mkdir -p /usr/share/doc/R-3.5.1/html/ && \
      mkdir -p /tmp/R/ && \
      echo "# Install script IRkernel" > rkernel_install.R && \
      echo "install.packages('pbdZMQ', lib='/tmp/R/', repos='http://cloud.r-project.org/')" >> rkernel_install.R && \
      echo "install.packages('repr', lib='/tmp/R/', repos='http://cloud.r-project.org/')" >> rkernel_install.R && \
      echo "install.packages('IRdisplay', lib='/tmp/R/', repos='http://cloud.r-project.org/')" >> rkernel_install.R && \
      echo "install.packages('evaluate', lib='/tmp/R/', repos='http://cloud.r-project.org/')" >> rkernel_install.R && \                
      echo "install.packages('crayon', lib='/tmp/R/', repos='http://cloud.r-project.org/')" >> rkernel_install.R && \
      echo "install.packages('uuid', lib='/tmp/R/', repos='http://cloud.r-project.org/')" >> rkernel_install.R && \
      echo "install.packages('digest', lib='/tmp/R/', repos='http://cloud.r-project.org/')" >> rkernel_install.R && \
      echo "install.packages('memoise', lib='/tmp/R/', repos='http://cloud.r-project.org/')" >> rkernel_install.R && \                
      echo "install.packages('git2r', lib='/tmp/R/', repos='http://cloud.r-project.org/')" >> rkernel_install.R && \    
      echo "install.packages('usethis', lib='/tmp/R/', repos='http://cloud.r-project.org/')" >> rkernel_install.R && \        
      echo "install.packages('devtools', lib='/tmp/R/', repos='http://cloud.r-project.org/')" >> rkernel_install.R && \
      echo "devtools::install_github('IRkernel/IRkernel')" >> rkernel_install.R && \    
      /tmp/anaconda3/bin/Rscript rkernel_install.R     
  
  CMD ["/tmp/anaconda3/bin/jupyterhub --help"]