-
Notifications
You must be signed in to change notification settings - Fork 217
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update dockerfile to include CCF build and source (#4702)
- Loading branch information
Showing
4 changed files
with
43 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +0,0 @@ | ||
* | ||
!getting_started | ||
!docker | ||
|
||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# CCF Continuous Integration image | ||
# Contains CCF build dependencies and toolchain for target platform | ||
# Also contains CCF source and build directory | ||
|
||
ARG platform=sgx | ||
|
||
# SGX | ||
FROM ubuntu:20.04 AS base-sgx | ||
|
||
WORKDIR / | ||
COPY ./docker/sgx_deps_pin.sh / | ||
RUN ./sgx_deps_pin.sh && rm ./sgx_deps_pin.sh | ||
|
||
# SNP | ||
FROM ubuntu:20.04 AS base-snp | ||
|
||
# Virtual | ||
FROM ubuntu:20.04 AS base-virtual | ||
|
||
# Final CCF CI image | ||
FROM base-${platform} AS final | ||
|
||
ARG platform=sgx | ||
ARG ansible_vars | ||
|
||
RUN echo "APT::Acquire::Retries \"5\";" | tee /etc/apt/apt.conf.d/80-retries | ||
|
||
COPY getting_started/setup_vm/ /tmp/setup_vm/ | ||
RUN apt update \ | ||
&& apt install -y ansible software-properties-common bsdmainutils dnsutils \ | ||
&& cd /tmp/setup_vm \ | ||
&& ansible-playbook ccf-dev.yml --extra-vars "$ansible_vars" --extra-vars "platform=${platform}" \ | ||
&& rm -rf /tmp/* \ | ||
&& apt remove -y ansible software-properties-common \ | ||
&& apt -y autoremove \ | ||
&& apt -y clean | ||
|
||
RUN mkdir /CCF | ||
COPY . /CCF/ | ||
RUN mkdir /CCF/build && cd /CCF/build && cmake -GNinja -DCOMPILE_TARGET=${platform} .. && ninja |