diff --git a/images/installer/Dockerfile b/images/installer/Dockerfile index 8fbe93608d1..15636253fa4 100644 --- a/images/installer/Dockerfile +++ b/images/installer/Dockerfile @@ -55,11 +55,7 @@ ENV PLAYBOOK_FILE=playbooks/byo/openshift_facts.yml \ # playbook2image's assemble script expects the source to be available in # /tmp/src (as per the source-to-image specs) so we import it there -ADD . /tmp/src - -# Running the 'assemble' script will install -# dependencies specified in requirements.txt -RUN /usr/bin/assemble +ADD . ${APP_HOME} WORKDIR ${APP_HOME} ENTRYPOINT [ "/usr/bin/entrypoint" ] diff --git a/images/installer/Dockerfile.rhel7 b/images/installer/Dockerfile.rhel7 index db5f1fabfc1..0f249976aa3 100644 --- a/images/installer/Dockerfile.rhel7 +++ b/images/installer/Dockerfile.rhel7 @@ -14,7 +14,6 @@ LABEL name="openshift3/ose-ansible" \ architecture="x86_64" # Playbooks, roles and their dependencies are installed from packages. -# Unlike in Dockerfile, we don't invoke the 'assemble' script here USER root RUN INSTALL_PKGS="atomic-openshift-utils atomic-openshift-clients python-boto skopeo openssl java-1.8.0-openjdk-headless httpd-tools" && \ yum repolist > /dev/null && \ @@ -49,9 +48,6 @@ ENV USER_NAME=default \ # The playbook to be run is specified via the PLAYBOOK_FILE env var. # This sets a default of openshift_facts.yml as it's an informative playbook # that can help test that everything is set properly (inventory, sshkeys). -# As the playbooks are installed via packages instead of being copied to -# $APP_HOME by the 'assemble' script, we set the WORK_DIR env var to the -# location of openshift-ansible. ENV PLAYBOOK_FILE=playbooks/byo/openshift_facts.yml \ ANSIBLE_CONFIG=/usr/share/atomic-openshift-utils/ansible.cfg \ WORK_DIR=/usr/share/ansible/openshift-ansible \ diff --git a/images/installer/bin/assemble b/images/installer/bin/assemble deleted file mode 100755 index 0d75d410b0c..00000000000 --- a/images/installer/bin/assemble +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash -e -# -# Assemble script for the openshift/openshift-ansible image. -# The 'assemble' script builds the application source so that it is ready to run. -# -# For more information refer to the documentation: -# https://github.com/openshift/source-to-image/blob/master/docs/builder_image.md -# - -if [[ "$1" == "-h" ]]; then - # If the assemble script is executed with '-h' flag, - # print the usage. - exec /usr/bin/usage -fi - -# Restore artifacts from the previous build (if they exist). -# -if [ "$(ls /tmp/artifacts/ 2>/dev/null)" ]; then - echo "---> Restoring build artifacts..." - mv /tmp/artifacts/. ./ -fi - -echo "---> Installing application source..." -cp -Rf /tmp/src/. ./ - -echo "---> Building application from source..." -# pre-create PYTHONUSERBASE/lib/*, otherwise pip creates it with mode 0700 -# which prevents containers with arbitrary UIDs to access local packages -mkdir -p ${HOME}/.local/lib/python2.7/site-packages -if [[ -v PYTHON_REQUIREMENTS ]]; then - pip install --no-cache-dir -r ${PYTHON_REQUIREMENTS} -elif [[ -e requirements.txt ]]; then - pip install --no-cache-dir --user -r requirements.txt -fi diff --git a/images/installer/bin/run b/images/installer/bin/run index d92a4dfb26f..9026dc622e7 100755 --- a/images/installer/bin/run +++ b/images/installer/bin/run @@ -15,11 +15,11 @@ if [[ -v INVENTORY_FILE ]]; then # contains a dynamic inventory and we use it directly. # Otherwise we make a copy so that ALLOW_ANSIBLE_CONNECTION_LOCAL below # does not attempt to modify the original - if [[ -x ${INVENTORY_FILE} ]]; then - INVENTORY="${INVENTORY_FILE}" - else - cp ${INVENTORY_FILE} ${INVENTORY} - fi + #if [[ -x ${INVENTORY_FILE} ]]; then + # INVENTORY="${INVENTORY_FILE}" + #else + cp ${INVENTORY_FILE} ${INVENTORY} + #fi elif [[ -v INVENTORY_URL ]]; then curl -o ${INVENTORY} ${INVENTORY_URL} elif [[ -v DYNAMIC_SCRIPT_URL ]]; then