Skip to content
This repository has been archived by the owner on Jul 20, 2023. It is now read-only.

Commit

Permalink
Update to presto 347 (#37)
Browse files Browse the repository at this point in the history
* Revert Dockerfile Changes to depend on upstream

* Update to prresto 347

* Update for 347

* Add back license claim

* Fix Dockerfile

* Add back arg to dockerfile

* Fix dockerfile again

* Fix user and group number in test_config

Co-authored-by: Ke Zhu <[email protected]>
  • Loading branch information
meneal and Ke Zhu authored Dec 14, 2020
1 parent 99c3386 commit f973b1d
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 34 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-latest

env:
PRESTO_VERSION: 340
PRESTO_VERSION: 347

steps:
- uses: actions/checkout@v2
Expand Down
31 changes: 4 additions & 27 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,36 +11,13 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
FROM centos:centos8

FROM prestosql/presto:347
ARG PRESTO_VERSION

ENV JAVA_HOME /usr/lib/jvm/zulu11
ENV LANG en_US.UTF-8

RUN \
set -xeu && \
dnf -y -q install https://cdn.azul.com/zulu/bin/zulu-repo-1.0.0-1.noarch.rpm && \
dnf -y -q update && \
dnf -y -q install zulu11 less python3 && \
alternatives --set python /usr/bin/python3 && \
rpm -i --nodeps https://repo1.maven.org/maven2/io/prestosql/presto-server-rpm/${PRESTO_VERSION}/presto-server-rpm-${PRESTO_VERSION}.rpm && \
dnf -q clean all && \
rm -rf /var/cache/dnf && \
rm -rf /tmp/* /var/tmp/* && \
mkdir -p /usr/lib/presto /data/presto && \
chown -R "presto:presto" /usr/lib/presto /data/presto

ADD https://repo1.maven.org/maven2/io/prestosql/presto-cli/${PRESTO_VERSION}/presto-cli-${PRESTO_VERSION}-executable.jar /usr/bin/presto
COPY bin/run-presto /usr/lib/presto/bin/
USER root
# Update centos packages
RUN dnf update -y

RUN chmod 0755 /usr/bin/presto && \
chmod 0755 /usr/lib/presto/bin/run-presto

EXPOSE 8080
USER presto:presto

CMD ["/usr/lib/presto/bin/run-presto"]

# Add Db2 connector
COPY --chown=presto:presto presto-db2-${PRESTO_VERSION} /usr/lib/presto/plugin/db2
12 changes: 6 additions & 6 deletions test_config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@ schemaVersion: "2.0.0"
fileExistenceTests:
- name: presto-home
path: /usr/lib/presto
uid: 998
gid: 996
uid: 1000
gid: 1000
- name: run-presto
path: /usr/lib/presto/bin/run-presto
permissions: '-rwxr-xr-x'
- name: presto-connector-db2
path: /usr/lib/presto/plugin/db2
uid: 998
gid: 996
uid: 1000
gid: 1000
- name: presto-db2.jar
path: /usr/lib/presto/plugin/db2/presto-db2-340.jar
path: /usr/lib/presto/plugin/db2/presto-db2-347.jar
metadataTest:
env:
- key: JAVA_HOME
value: /usr/lib/jvm/zulu11
exposedPorts: ["8080"]
cmd:
- /usr/lib/presto/bin/run-presto
- /usr/lib/presto/bin/run-presto

0 comments on commit f973b1d

Please sign in to comment.