Skip to content

Commit

Permalink
Try a docker file
Browse files Browse the repository at this point in the history
  • Loading branch information
donporter committed Oct 28, 2024
1 parent 8c87330 commit 2c7d474
Show file tree
Hide file tree
Showing 2 changed files with 69 additions and 6 deletions.
6 changes: 0 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,6 @@ For more detailed output, use:

`docker buildx build . --progress=plain`

You can confirm the built image is for multiple architectures using

`docker image inspect TAG`

where "TAG" is the name of the image.

The full command to build and push (requires privilege) is:

`docker buildx build --tag index.docker.io/oscar1ab/needledb:latest --platform linux/amd64 --push .`
Expand Down
69 changes: 69 additions & 0 deletions needledb/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
# Rolling forward to 18.04
FROM ubuntu:18.04

SHELL ["/bin/bash", "-c"]

ENV DEBIAN_FRONTEND noninteractive

# Add Node.js v10 APT repo

RUN apt-get clean
RUN apt-get update
RUN apt-get install -y curl gnupg

RUN curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add -

RUN sh -c "echo deb https://deb.nodesource.com/node_10.x bionic main > /etc/apt/sources.list.d/nodesource.list"

# Packages needed to build filesystem and run xfstests
RUN apt-get clean
RUN apt-get update
RUN apt-get install -y \
automake \
autoconf \
build-essential \
cmake \
debhelper \
gcc \
git \
libaio-dev \
libcurl4-openssl-dev \
libprotobuf-dev \
libssl-dev \
libtool \
libxxhash-dev \
make \
nodejs \
ocaml \
ocamlbuild \
perl \
protobuf-compiler \
python \
reprepro \
sysstat \
unzip \
wget

# Install SGX SDK
RUN git clone https://github.com/intel/linux-sgx.git
RUN cd linux-sgx && git checkout sgx_2.12
RUN cd linux-sgx && make preparation && cp external/toolset/ubuntu18.04/* /usr/local/bin
RUN cd linux-sgx && make sdk_install_pkg
RUN ./linux-sgx/linux/installer/bin/sgx_linux_x64_sdk_2.12.100.3.bin --prefix /opt/intel

# (a) Install PSW
# RUN cd linux-sgx && make deb_psw_pkg
# RUN dpkg -i linux-sgx/linux/installer/deb/libsgx-headers/*.deb
# RUN dpkg -i linux-sgx/linux/installer/deb/libsgx-enclave-common/*.deb
# RUN dpkg -i linux-sgx/linux/installer/deb/libsgx-urts/*.deb
# RUN dpkg -i linux-sgx/linux/installer/deb/libsgx-epid/*.deb
# RUN dpkg -i linux-sgx/linux/installer/deb/libsgx-launch/*.deb
# RUN dpkg -i linux-sgx/linux/installer/deb/libsgx-quote-ex/*.deb
# RUN dpkg -i linux-sgx/linux/installer/deb/libsgx-uae-service/*.deb

# Install SGX SSL Library
RUN git clone https://github.com/intel/intel-sgx-ssl.git
RUN cd intel-sgx-ssl/openssl_source && wget https://github.com/openssl/openssl/releases/download/openssl-3.0.13/openssl-3.0.13.tar.gz
RUN cd intel-sgx-ssl/Linux && source /opt/intel/sgxsdk/environment && make all && make install

CMD ["bash"]

0 comments on commit 2c7d474

Please sign in to comment.