| 
									
										
										
										
											2022-07-06 17:14:06 +08:00
										 |  |  | //go:build darwin
 | 
					
						
							| 
									
										
										
										
											2020-09-24 23:40:57 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | package buildah | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | import ( | 
					
						
							| 
									
										
										
										
											2022-07-06 17:14:06 +08:00
										 |  |  | 	"errors" | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-06-22 16:26:21 +08:00
										 |  |  | 	"github.com/containers/buildah/define" | 
					
						
							| 
									
										
										
										
											2022-07-06 17:14:06 +08:00
										 |  |  | 	"github.com/opencontainers/runtime-spec/specs-go" | 
					
						
							| 
									
										
										
										
											2025-08-29 20:55:12 +08:00
										 |  |  | 	nettypes "go.podman.io/common/libnetwork/types" | 
					
						
							|  |  |  | 	"go.podman.io/storage" | 
					
						
							| 
									
										
										
										
											2020-09-24 23:40:57 +08:00
										 |  |  | ) | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | // ContainerDevices is an alias for a slice of github.com/opencontainers/runc/libcontainer/configs.Device structures.
 | 
					
						
							| 
									
										
										
										
											2021-06-22 16:26:21 +08:00
										 |  |  | type ContainerDevices define.ContainerDevices | 
					
						
							| 
									
										
										
										
											2020-09-24 23:40:57 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | func setChildProcess() error { | 
					
						
							|  |  |  | 	return errors.New("function not supported on non-linux systems") | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | func runUsingRuntimeMain() {} | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | func (b *Builder) Run(command []string, options RunOptions) error { | 
					
						
							|  |  |  | 	return errors.New("function not supported on non-linux systems") | 
					
						
							|  |  |  | } | 
					
						
							| 
									
										
										
										
											2024-08-16 00:50:07 +08:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-09-24 23:40:57 +08:00
										 |  |  | func DefaultNamespaceOptions() (NamespaceOptions, error) { | 
					
						
							| 
									
										
										
										
											2021-01-25 21:01:01 +08:00
										 |  |  | 	options := NamespaceOptions{ | 
					
						
							|  |  |  | 		{Name: string(specs.CgroupNamespace), Host: false}, | 
					
						
							|  |  |  | 		{Name: string(specs.IPCNamespace), Host: false}, | 
					
						
							|  |  |  | 		{Name: string(specs.MountNamespace), Host: false}, | 
					
						
							|  |  |  | 		{Name: string(specs.NetworkNamespace), Host: false}, | 
					
						
							|  |  |  | 		{Name: string(specs.PIDNamespace), Host: false}, | 
					
						
							|  |  |  | 		{Name: string(specs.UserNamespace), Host: false}, | 
					
						
							|  |  |  | 		{Name: string(specs.UTSNamespace), Host: false}, | 
					
						
							|  |  |  | 	} | 
					
						
							|  |  |  | 	return options, nil | 
					
						
							| 
									
										
										
										
											2020-09-24 23:40:57 +08:00
										 |  |  | } | 
					
						
							| 
									
										
										
										
											2022-01-06 04:36:49 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | // getNetworkInterface creates the network interface
 | 
					
						
							|  |  |  | func getNetworkInterface(store storage.Store, cniConfDir, cniPluginPath string) (nettypes.ContainerNetwork, error) { | 
					
						
							| 
									
										
										
										
											2022-06-09 18:06:13 +08:00
										 |  |  | 	return nil, nil | 
					
						
							| 
									
										
										
										
											2022-01-06 04:36:49 +08:00
										 |  |  | } |