Update https_server demo with copy_bom tool
Signed-off-by: Zheng, Qi <huaiqing.zq@antgroup.com>
This commit is contained in:
		
							parent
							
								
									cbb326e3fd
								
							
						
					
					
						commit
						1f1fd9102b
					
				
							
								
								
									
										16
									
								
								demos/https_server/https.yaml
									
									
									
									
									
										Normal file
									
								
							
							
								
								
								
								
								
									
									
								
							
						
						
									
										16
									
								
								demos/https_server/https.yaml
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,16 @@ | |||||||
|  | includes: | ||||||
|  |   - base.yaml | ||||||
|  | # https_server | ||||||
|  | targets: | ||||||
|  |   # copy bin | ||||||
|  |   - target: /bin | ||||||
|  |     copy: | ||||||
|  |       - files: | ||||||
|  |         - ../mongoose_src/examples/simplest_web_server_ssl/$https_server | ||||||
|  |   # copy keys | ||||||
|  |   - target: / | ||||||
|  |     copy: | ||||||
|  |       - files: | ||||||
|  |         - ../mongoose_src/examples/simplest_web_server_ssl/server.key | ||||||
|  |         - ../mongoose_src/examples/simplest_web_server_ssl/server.pem | ||||||
|  | 
 | ||||||
| @ -1,7 +1,10 @@ | |||||||
| #!/bin/bash | #!/bin/bash | ||||||
| https_server=simplest_web_server_ssl | export https_server=simplest_web_server_ssl | ||||||
| set -e | set -e | ||||||
| 
 | 
 | ||||||
|  | SCRIPT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd ) | ||||||
|  | bomfile=${SCRIPT_DIR}/https.yaml | ||||||
|  | 
 | ||||||
| # 1. Init Occlum Workspace | # 1. Init Occlum Workspace | ||||||
| rm -rf occlum_workspace | rm -rf occlum_workspace | ||||||
| mkdir occlum_workspace | mkdir occlum_workspace | ||||||
| @ -9,10 +12,9 @@ cd occlum_workspace | |||||||
| occlum init | occlum init | ||||||
| 
 | 
 | ||||||
| # 2. Copy files into Occlum Workspace and Build | # 2. Copy files into Occlum Workspace and Build | ||||||
| cp ../mongoose_src/examples/simplest_web_server_ssl/$https_server image/bin | rm -rf image | ||||||
| cp -r ../mongoose_src/examples/simplest_web_server_ssl/server.* image | copy_bom -f $bomfile --root image --include-dir /opt/occlum/etc/template | ||||||
| cp /usr/local/occlum/x86_64-linux-musl/lib/libssl.so.1.1 image/lib | 
 | ||||||
| cp /usr/local/occlum/x86_64-linux-musl/lib/libcrypto.so.1.1 image/lib |  | ||||||
| occlum build | occlum build | ||||||
| 
 | 
 | ||||||
| # 3. Run https_server | # 3. Run https_server | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user