Dockerfile 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. # syntax=docker/dockerfile:experimental
  2. #
  3. # Copyright 2018-2022 Elyra Authors
  4. #
  5. # Licensed under the Apache License, Version 2.0 (the "License");
  6. # you may not use this file except in compliance with the License.
  7. # You may obtain a copy of the License at
  8. #
  9. # http://www.apache.org/licenses/LICENSE-2.0
  10. #
  11. # Unless required by applicable law or agreed to in writing, software
  12. # distributed under the License is distributed on an "AS IS" BASIS,
  13. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14. # See the License for the specific language governing permissions and
  15. # limitations under the License.
  16. #
  17. # Ubuntu 20.04.2 LTS (Focal Fossa)
  18. # Repository: https://gallery.ecr.aws/j1r0q0g6/notebooks/notebook-servers/jupyter
  19. FROM public.ecr.aws/j1r0q0g6/notebooks/notebook-servers/jupyter:v1.4
  20. ARG TAG="dev"
  21. ARG ELYRA_VERSION
  22. ARG ELYRA_PACKAGE=elyra-"$ELYRA_VERSION"-py3-none-any.whl
  23. # - Include with KFP Tekton support ('kfp-tekton') and component examples ('kfp-examples')
  24. ARG ELYRA_EXTRAS=[kfp-tekton,kfp-examples]
  25. # Includes the readme as a token file for COPY that always exists, otherwise production builds fail when whl not present
  26. COPY $ELYRA_PACKAGE README.md ./
  27. # Install Elyra
  28. RUN if [ "$TAG" = "dev" ] ; then \
  29. python -m pip install --quiet --no-cache-dir "$ELYRA_PACKAGE""$ELYRA_EXTRAS"; \
  30. else \
  31. python -m pip install --quiet --no-cache-dir elyra"$ELYRA_EXTRAS"=="$TAG" ; fi
  32. # Cleanup
  33. USER root
  34. RUN rm $ELYRA_PACKAGE README.md
  35. USER jovyan
  36. # Install component examples catalog
  37. # - this will fail if the 'kfp-examples' pip extra is not installed
  38. RUN elyra-metadata create component-catalogs \
  39. --schema_name=elyra-kfp-examples-catalog \
  40. --display_name="Kubeflow Pipelines examples" \
  41. --runtime_type=KUBEFLOW_PIPELINES \
  42. --categories="['examples']"