diff --git a/README.md b/README.md index 110e282c..2c2ccfa4 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ Note that the Occlum toolchain is not cross-compiling in the traditional sense: **Step 2. Initialize a directory as the Occlum instance via `occlum init`** ``` -$ mkdir occlum_context && cd occlum_context +$ mkdir occlum_instance && cd occlum_instance $ occlum init ``` The `occlum init` command creates the compile-time and run-time state of Occlum in the current working directory. Each Occlum instance directory should be used for a single instance of an application; multiple applications or different instances of a single application should use different Occlum instances. diff --git a/demos/embedded_mode/.gitignore b/demos/embedded_mode/.gitignore index d271a39c..6101cdb9 100644 --- a/demos/embedded_mode/.gitignore +++ b/demos/embedded_mode/.gitignore @@ -1,2 +1,2 @@ .occlum -occlum_context +occlum_instance diff --git a/demos/embedded_mode/Makefile b/demos/embedded_mode/Makefile index 39965186..4c74ddba 100644 --- a/demos/embedded_mode/Makefile +++ b/demos/embedded_mode/Makefile @@ -3,15 +3,15 @@ SGX_MODE ?= HW .PHONY: all build_src test clean -all: occlum_context +all: occlum_instance -occlum_context: build_src - @mkdir -p occlum_context - @cd occlum_context && \ +occlum_instance: build_src + @mkdir -p occlum_instance + @cd occlum_instance && \ occlum init && \ cp ../trusted_memcpy_bench/build/trusted_memcpy_bench image/bin/ && \ occlum build - @cp -r occlum_context/.occlum .occlum + @cp -r occlum_instance/.occlum .occlum build_src: @$(MAKE) --no-print-directory -C trusted_memcpy_bench @@ -25,4 +25,4 @@ test: clean: @$(MAKE) --no-print-directory -C trusted_memcpy_bench clean @$(MAKE) --no-print-directory -C bench_driver clean - @rm -rf .occlum occlum_context + @rm -rf .occlum occlum_instance diff --git a/demos/fish/.gitignore b/demos/fish/.gitignore index 2c9a818a..10ca7d5e 100644 --- a/demos/fish/.gitignore +++ b/demos/fish/.gitignore @@ -1,5 +1,5 @@ ncurses/ fish-shell/ busybox/ -occlum-context/ +occlum-instance/ occlum-test/ diff --git a/demos/fish/run_fish_test.sh b/demos/fish/run_fish_test.sh index 5176849c..e3c1e014 100755 --- a/demos/fish/run_fish_test.sh +++ b/demos/fish/run_fish_test.sh @@ -1,8 +1,8 @@ #!/bin/bash set -e -rm -rf occlum-context -mkdir occlum-context && cd occlum-context +rm -rf occlum-instance +mkdir occlum-instance && cd occlum-instance occlum init mkdir -p image/usr/bin cp ../Occlum.json . diff --git a/demos/gdb_support/.gitignore b/demos/gdb_support/.gitignore index 486f2cc1..0b6e3c72 100644 --- a/demos/gdb_support/.gitignore +++ b/demos/gdb_support/.gitignore @@ -1,2 +1,2 @@ sample -occlum_context +occlum_instance diff --git a/demos/gdb_support/gdb_sample_on_occlum.sh b/demos/gdb_support/gdb_sample_on_occlum.sh index a903a50c..d4e2566e 100755 --- a/demos/gdb_support/gdb_sample_on_occlum.sh +++ b/demos/gdb_support/gdb_sample_on_occlum.sh @@ -1,8 +1,8 @@ #!/bin/bash set -e -rm -rf occlum_context && mkdir -p occlum_context -cd occlum_context +rm -rf occlum_instance && mkdir -p occlum_instance +cd occlum_instance # 1. Initialize a directory as the Occlum instance occlum init diff --git a/demos/golang/.gitignore b/demos/golang/.gitignore index 5cc03124..cb1e5775 100644 --- a/demos/golang/.gitignore +++ b/demos/golang/.gitignore @@ -1,2 +1,2 @@ -occlum_context/ +occlum_instance/ web_server diff --git a/demos/golang/run_golang_on_occlum.sh b/demos/golang/run_golang_on_occlum.sh index a5295cf5..d01401b0 100755 --- a/demos/golang/run_golang_on_occlum.sh +++ b/demos/golang/run_golang_on_occlum.sh @@ -13,8 +13,8 @@ if [ ! -f $web_server ];then fi # 1. Init Occlum Workspace -rm -rf occlum_context && mkdir occlum_context -cd occlum_context +rm -rf occlum_instance && mkdir occlum_instance +cd occlum_instance occlum init new_json="$(jq '.resource_limits.user_space_size = "380MB" | .process.default_mmap_size = "300MB"' Occlum.json)" && \ diff --git a/demos/grpc/run_client_on_occlum.sh b/demos/grpc/run_client_on_occlum.sh index 0da03743..d8bac2d6 100755 --- a/demos/grpc/run_client_on_occlum.sh +++ b/demos/grpc/run_client_on_occlum.sh @@ -12,9 +12,9 @@ then exit 1 fi -rm -rf occlum_context -mkdir occlum_context -cd occlum_context +rm -rf occlum_instance +mkdir occlum_instance +cd occlum_instance occlum init if [ $? -ne 0 ] diff --git a/demos/grpc/run_server_on_occlum.sh b/demos/grpc/run_server_on_occlum.sh index 0da98cba..2554f486 100755 --- a/demos/grpc/run_server_on_occlum.sh +++ b/demos/grpc/run_server_on_occlum.sh @@ -11,9 +11,9 @@ then exit 1 fi -rm -rf occlum_context -mkdir occlum_context -cd occlum_context +rm -rf occlum_instance +mkdir occlum_instance +cd occlum_instance occlum init if [ $? -ne 0 ] diff --git a/demos/java/.gitignore b/demos/java/.gitignore index 7db3632b..78b29d71 100644 --- a/demos/java/.gitignore +++ b/demos/java/.gitignore @@ -1,3 +1,3 @@ -occlum_context/ +occlum_instance/ gs-messaging-stomp-websocket/ */*.class diff --git a/demos/java/run_java_on_occlum.sh b/demos/java/run_java_on_occlum.sh index 31960ace..7acc411b 100755 --- a/demos/java/run_java_on_occlum.sh +++ b/demos/java/run_java_on_occlum.sh @@ -21,8 +21,8 @@ check_file_exist() { init_workspace() { # Init Occlum Workspace - rm -rf occlum_context && mkdir occlum_context - cd occlum_context + rm -rf occlum_instance && mkdir occlum_instance + cd occlum_instance occlum init new_json="$(jq '.resource_limits.user_space_size = "1400MB" | .resource_limits.kernel_space_heap_size="64MB" | diff --git a/demos/local_attestation/.gitignore b/demos/local_attestation/.gitignore index b4f9dc2d..726ee7a7 100644 --- a/demos/local_attestation/.gitignore +++ b/demos/local_attestation/.gitignore @@ -1,6 +1,6 @@ bin deps -occlum_context +occlum_instance DiffieHellmanLibrary/*.cpp DiffieHellmanLibrary/*.so DiffieHellmanLibrary/*.o diff --git a/demos/local_attestation/Makefile b/demos/local_attestation/Makefile index 44b61cf9..47dd5f1e 100644 --- a/demos/local_attestation/Makefile +++ b/demos/local_attestation/Makefile @@ -10,17 +10,17 @@ occlum_=$(CUR_DIR)/../.. .PHONY: all build_src test clean -all: occlum_context +all: occlum_instance -occlum_context: build_src - @mkdir -p occlum_context - @cd occlum_context && \ +occlum_instance: build_src + @mkdir -p occlum_instance + @cd occlum_instance && \ occlum init && \ cp $(CUR_DIR)/AppResponder/responder image/bin/ && \ cp $(OPENSSL)/libcrypto.so.1.1 image/lib/ && \ cp $(CUR_DIR)/DiffieHellmanLibrary/libecdh.so image/lib/ && \ occlum build - @cp -r occlum_context/.occlum .occlum + @cp -r occlum_instance/.occlum .occlum build_src: @$(MAKE) --no-print-directory -C DiffieHellmanLibrary @@ -37,4 +37,4 @@ clean: @$(MAKE) --no-print-directory -C AppResponder clean @$(MAKE) --no-print-directory -C EnclaveInitiator clean @$(MAKE) --no-print-directory -C DiffieHellmanLibrary clean - @rm -rf .occlum occlum_context $(BUILD_DIR) + @rm -rf .occlum occlum_instance $(BUILD_DIR) diff --git a/demos/openvino/.gitignore b/demos/openvino/.gitignore index b3032582..b1f74884 100644 --- a/demos/openvino/.gitignore +++ b/demos/openvino/.gitignore @@ -1,4 +1,4 @@ deps/ openvino_src/ model/ -occlum_context/ +occlum_instance/ diff --git a/demos/openvino/run_benchmark_on_occlum.sh b/demos/openvino/run_benchmark_on_occlum.sh index bb9b0a9a..15ad8ecd 100755 --- a/demos/openvino/run_benchmark_on_occlum.sh +++ b/demos/openvino/run_benchmark_on_occlum.sh @@ -5,9 +5,9 @@ occlum_lib=/usr/local/occlum/x86_64-linux-musl/lib set -e # 1. Init Occlum Workspace -rm -rf occlum_context -mkdir occlum_context -cd occlum_context +rm -rf occlum_instance +mkdir occlum_instance +cd occlum_instance occlum init new_json="$(jq '.resource_limits.user_space_size = "320MB" | .process.default_mmap_size = "256MB"' Occlum.json)" && \ diff --git a/demos/python/.gitignore b/demos/python/.gitignore index 1be33f78..1e1cb50b 100644 --- a/demos/python/.gitignore +++ b/demos/python/.gitignore @@ -1 +1 @@ -occlum_context/ +occlum_instance/ diff --git a/demos/python/README.md b/demos/python/README.md index aa0a568b..52eb48a7 100644 --- a/demos/python/README.md +++ b/demos/python/README.md @@ -38,4 +38,4 @@ Step 4 (in the Occlum container): Run the sample code on Occlum via ``` ./run_python_on_occlum.sh ``` -It will process CSV data files and generate a file (`smvlight.dat`) in `./occlum_context`. +It will process CSV data files and generate a file (`smvlight.dat`) in `./occlum_instance`. diff --git a/demos/python/run_python_on_occlum.sh b/demos/python/run_python_on_occlum.sh index 50cabd62..d541cf78 100755 --- a/demos/python/run_python_on_occlum.sh +++ b/demos/python/run_python_on_occlum.sh @@ -12,8 +12,8 @@ if [ ! -d $alpine_fs ];then fi # 1. Init Occlum Workspace -[ -d occlum_context ] || mkdir occlum_context -cd occlum_context +[ -d occlum_instance ] || mkdir occlum_instance +cd occlum_instance [ -d image ] || occlum init # 2. Copy files into Occlum Workspace and build diff --git a/demos/rust/run_rust_demo_on_occlum.sh b/demos/rust/run_rust_demo_on_occlum.sh index 116132d0..b446e148 100755 --- a/demos/rust/run_rust_demo_on_occlum.sh +++ b/demos/rust/run_rust_demo_on_occlum.sh @@ -7,7 +7,7 @@ occlum-cargo build popd # initialize occlum workspace -rm -rf occlum_context && mkdir occlum_context && cd occlum_context +rm -rf occlum_instance && mkdir occlum_instance && cd occlum_instance occlum init cp ../rust_app/target/x86_64-unknown-linux-musl/debug/rust_app image/bin diff --git a/demos/sqlite/.gitignore b/demos/sqlite/.gitignore index 30a1b8a3..46f353c3 100644 --- a/demos/sqlite/.gitignore +++ b/demos/sqlite/.gitignore @@ -1,3 +1,3 @@ sqlite_src/ -occlum_context/ +occlum_instance/ sqlite_demo diff --git a/demos/sqlite/run_sqlite_on_occlum.sh b/demos/sqlite/run_sqlite_on_occlum.sh index 5d4495b1..d622d71a 100755 --- a/demos/sqlite/run_sqlite_on_occlum.sh +++ b/demos/sqlite/run_sqlite_on_occlum.sh @@ -19,8 +19,8 @@ if [ ! -e $DEMO ];then fi # 1. Init Occlum Workspace -rm -rf occlum_context && mkdir occlum_context -cd occlum_context +rm -rf occlum_instance && mkdir occlum_instance +cd occlum_instance occlum init # 2. Copy files into Occlum Workspace and build