Skip to content

Commit

Permalink
Merge pull request #1 from guimou/optaplanner
Browse files Browse the repository at this point in the history
Adding optapy image
  • Loading branch information
guimou authored Mar 23, 2022
2 parents 507a857 + 99d7a08 commit bf69230
Show file tree
Hide file tree
Showing 5 changed files with 69 additions and 0 deletions.
22 changes: 22 additions & 0 deletions optapy-notebook/container/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
FROM quay.io/thoth-station/s2i-minimal-f34-py39-notebook:v0.2.2

USER root

# Install JDK
RUN yum -y update && \
yum -y install java-11-openjdk java-11-openjdk-devel && \
yum -y clean all && \
rm -rf /var/cache/dnf

WORKDIR /tmp/

# Copying custom packages
COPY requirements.txt /tmp/

# Install custom packages
RUN micropipenv install --deploy

WORKDIR /opt/app-root/src
USER 1001

CMD /opt/app-root/bin/start-singleuser.sh --ip=0.0.0.0 --port=8080
7 changes: 7 additions & 0 deletions optapy-notebook/container/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# OptaPy Notebook

Custom notebook based on RHODS standard data science notebook, adding:

* [OptaPy](http://www.optapy.org/) ([Github repo](https://github.com/optapy/optapy))

Every organization faces planning problems: providing products or services with a limited set of constrained resources (employees, assets, time and money). OptaPy optimizes such planning to do more business with less resources. This is known as Constraint Satisfaction Programming (which is part of the Operations Research discipline).
6 changes: 6 additions & 0 deletions optapy-notebook/container/requirements.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
--index-url https://pypi.org/simple
#
# Default dependencies
#

# Empty now as OptaPy is in pre-release which is not accepted by pip-compile
7 changes: 7 additions & 0 deletions optapy-notebook/container/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#
# This file is autogenerated by pip-compile with python 3.8
# To update, run:
#
# pip-compile --generate-hashes requirements.in
#
optapy==8.17.0a0
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
kind: ImageStream
apiVersion: image.openshift.io/v1
metadata:
annotations:
opendatahub.io/notebook-image-desc: >-
JupyterLab notebook image with OptaPy.
opendatahub.io/notebook-image-name: Minimal DataScience notebook with OptaPy
opendatahub.io/notebook-image-url: 'https://github.com/guimou/custom-notebooks/tree/main/optapy-notebook'
name: s2i-minimal-data-science-optapy-notebook
labels:
component.opendatahub.io/name: jupyterhub
opendatahub.io/component: 'true'
opendatahub.io/notebook-image: 'true'
spec:
lookupPolicy:
local: true
tags:
- name: latest
annotations:
opendatahub.io/notebook-python-dependencies: >-
[{"name":"OptaPy","version":""}]
opendatahub.io/notebook-software: '[{"name":"Python","version":"v3.9.7"}]'
from:
kind: DockerImage
name: 'quay.io/guimou/s2i-minimal-data-science-optapy-notebook:latest'
referencePolicy:
type: Source

0 comments on commit bf69230

Please sign in to comment.