mirror of
				https://github.com/containers/podman.git
				synced 2025-11-01 02:42:11 +08:00 
			
		
		
		
	 482ef7bfcf
			
		
	
	482ef7bfcf
	
	
	
		
			
			This is something Docker does, and we did not do until now. Most difficult/annoying part was the REST API, where I did not really want to modify the struct being sent, so I made the new restart policy parameters query parameters instead. Testing was also a bit annoying, because testing restart policy always is. Signed-off-by: Matt Heon <mheon@redhat.com>
		
			
				
	
	
		
			81 lines
		
	
	
		
			1.8 KiB
		
	
	
	
		
			Markdown
		
	
	
	
	
	
			
		
		
	
	
			81 lines
		
	
	
		
			1.8 KiB
		
	
	
	
		
			Markdown
		
	
	
	
	
	
| % podman-update 1
 | |
| 
 | |
| ## NAME
 | |
| podman\-update - Update the configuration of a given container
 | |
| 
 | |
| ## SYNOPSIS
 | |
| **podman update** [*options*] *container*
 | |
| 
 | |
| **podman container update** [*options*] *container*
 | |
| 
 | |
| ## DESCRIPTION
 | |
| 
 | |
| Updates the configuration of an already existing container, allowing different resource limits to be set.
 | |
| The currently supported options are a subset of the podman create/run resource limit options.
 | |
| 
 | |
| ## OPTIONS
 | |
| 
 | |
| @@option blkio-weight
 | |
| 
 | |
| @@option blkio-weight-device
 | |
| 
 | |
| @@option cpu-period
 | |
| 
 | |
| @@option cpu-quota
 | |
| 
 | |
| @@option cpu-rt-period
 | |
| 
 | |
| @@option cpu-rt-runtime
 | |
| 
 | |
| @@option cpu-shares
 | |
| 
 | |
| @@option cpus.container
 | |
| 
 | |
| @@option cpuset-cpus
 | |
| 
 | |
| @@option cpuset-mems
 | |
| 
 | |
| @@option device-read-bps
 | |
| 
 | |
| @@option device-read-iops
 | |
| 
 | |
| @@option device-write-bps
 | |
| 
 | |
| @@option device-write-iops
 | |
| 
 | |
| @@option memory
 | |
| 
 | |
| @@option memory-reservation
 | |
| 
 | |
| @@option memory-swap
 | |
| 
 | |
| @@option memory-swappiness
 | |
| 
 | |
| @@option pids-limit
 | |
| 
 | |
| @@option restart
 | |
| 
 | |
| 
 | |
| ## EXAMPLEs
 | |
| 
 | |
| Update a container with a new cpu quota and period.
 | |
| ```
 | |
| podman update --cpus=5 myCtr
 | |
| ```
 | |
| 
 | |
| Update a container with all available options for cgroups v2.
 | |
| ```
 | |
| podman update --cpus 5 --cpuset-cpus 0 --cpu-shares 123 --cpuset-mems 0 --memory 1G --memory-swap 2G --memory-reservation 2G --blkio-weight-device /dev/zero:123 --blkio-weight 123 --device-read-bps /dev/zero:10mb --device-write-bps /dev/zero:10mb --device-read-iops /dev/zero:1000 --device-write-iops /dev/zero:1000 --pids-limit 123 ctrID
 | |
| ```
 | |
| 
 | |
| Update a container with all available options for cgroups v1.
 | |
| ```
 | |
| podman update --cpus 5 --cpuset-cpus 0 --cpu-shares 123 --cpuset-mems 0 --memory 1G --memory-swap 2G --memory-reservation 2G --memory-swappiness 50 --pids-limit 123 ctrID
 | |
| ```
 | |
| 
 | |
| ## SEE ALSO
 | |
| **[podman(1)](podman.1.md)**, **[podman-create(1)](podman-create.1.md)**, **[podman-run(1)](podman-run.1.md)**
 | |
| 
 | |
| ## HISTORY
 | |
| August 2022, Originally written by Charlie Doern <cdoern@redhat.com>
 |