|
@@ -0,0 +1,30 @@
|
|
|
+FROM ubuntu:22.04 AS sgx
|
|
|
+RUN apt update && apt install -y build-essential ocaml ocamlbuild \
|
|
|
+ automake autoconf libtool wget python-is-python3 libssl-dev \
|
|
|
+ git cmake perl unzip debhelper libcurl4-openssl-dev \
|
|
|
+ protobuf-compiler reprepro
|
|
|
+WORKDIR /root
|
|
|
+RUN git clone https://github.com/intel/linux-sgx
|
|
|
+WORKDIR /root/linux-sgx
|
|
|
+RUN git checkout sgx_2.22
|
|
|
+RUN make preparation
|
|
|
+RUN make sdk_install_pkg
|
|
|
+RUN cd linux/installer/bin/ && echo -e "no\n/opt/intel" | ./sgx_linux_x64_sdk_2.22*
|
|
|
+RUN make psw_install_pkg
|
|
|
+RUN cd linux/installer/bin/ && ./sgx_linux_x64_psw_2.22* --no-start-aesm
|
|
|
+WORKDIR /root
|
|
|
+RUN git clone https://github.com/intel/intel-sgx-ssl
|
|
|
+WORKDIR /root/intel-sgx-ssl/openssl_source
|
|
|
+RUN wget https://www.openssl.org/source/openssl-3.0.12.tar.gz
|
|
|
+WORKDIR /root/intel-sgx-ssl/Linux
|
|
|
+RUN make
|
|
|
+RUN make install
|
|
|
+WORKDIR /root
|
|
|
+RUN addgroup sgx
|
|
|
+RUN addgroup sgx_prv
|
|
|
+RUN adduser aesmd sgx
|
|
|
+RUN adduser aesmd sgx_prv
|
|
|
+COPY start-aesmd /usr/local/sbin
|
|
|
+RUN chown aesmd.aesmd /var/run/aesmd
|
|
|
+RUN chmod 755 /usr/local/sbin/start-aesmd
|
|
|
+ENTRYPOINT ["/usr/local/sbin/start-aesmd"]
|