providers/docker: pull setting, default false [GH-5932]
This commit is contained in:
parent
f26293bb06
commit
bac5d039db
|
@ -8,7 +8,8 @@ BUG FIXES:
|
||||||
- guests/ubuntu: setting hostname fixed in 12.04 [GH-5937]
|
- guests/ubuntu: setting hostname fixed in 12.04 [GH-5937]
|
||||||
- hosts/linux: NFS can be configured without `$TMP` set on the host [GH-5954]
|
- hosts/linux: NFS can be configured without `$TMP` set on the host [GH-5954]
|
||||||
- hosts/linux: NFS will sudo copying back to `/etc/exports` [GH-5957]
|
- hosts/linux: NFS will sudo copying back to `/etc/exports` [GH-5957]
|
||||||
- providers/virtulabox: remove UNC path conversion on Windows since it
|
- providers/docker: Add `pull` setting, default to false [GH-5932]
|
||||||
|
- providers/virtualbox: remove UNC path conversion on Windows since it
|
||||||
caused mounting regressions [GH-5933]
|
caused mounting regressions [GH-5933]
|
||||||
- provisioners/puppet: Windows Puppet 4 paths work correctly [GH-5967]
|
- provisioners/puppet: Windows Puppet 4 paths work correctly [GH-5967]
|
||||||
- provisioners/puppet: Fix config merging errors [GH-5958]
|
- provisioners/puppet: Fix config merging errors [GH-5958]
|
||||||
|
|
|
@ -13,7 +13,7 @@ module VagrantPlugins
|
||||||
@driver = @machine.provider.driver
|
@driver = @machine.provider.driver
|
||||||
|
|
||||||
# Skip pulling if the image is built
|
# Skip pulling if the image is built
|
||||||
return @app.call(env) if @env[:create_image]
|
return @app.call(env) if @env[:create_image] || !@provider_config.pull
|
||||||
|
|
||||||
image = @provider_config.image
|
image = @provider_config.image
|
||||||
env[:ui].output(I18n.t("docker_provider.pull", image: image))
|
env[:ui].output(I18n.t("docker_provider.pull", image: image))
|
||||||
|
|
|
@ -61,6 +61,12 @@ module VagrantPlugins
|
||||||
# @return [String]
|
# @return [String]
|
||||||
attr_accessor :name
|
attr_accessor :name
|
||||||
|
|
||||||
|
# If true, the image will be pulled on every `up` and `reload`
|
||||||
|
# to ensure the latest image.
|
||||||
|
#
|
||||||
|
# @return [Bool]
|
||||||
|
attr_accessor :pull
|
||||||
|
|
||||||
# True if the docker container is meant to stay in the "running"
|
# True if the docker container is meant to stay in the "running"
|
||||||
# state (is a long running process). By default this is true.
|
# state (is a long running process). By default this is true.
|
||||||
#
|
#
|
||||||
|
@ -140,6 +146,7 @@ module VagrantPlugins
|
||||||
@image = UNSET_VALUE
|
@image = UNSET_VALUE
|
||||||
@name = UNSET_VALUE
|
@name = UNSET_VALUE
|
||||||
@links = []
|
@links = []
|
||||||
|
@pull = UNSET_VALUE
|
||||||
@ports = UNSET_VALUE
|
@ports = UNSET_VALUE
|
||||||
@privileged = UNSET_VALUE
|
@privileged = UNSET_VALUE
|
||||||
@remains_running = UNSET_VALUE
|
@remains_running = UNSET_VALUE
|
||||||
|
@ -199,6 +206,7 @@ module VagrantPlugins
|
||||||
@has_ssh = false if @has_ssh == UNSET_VALUE
|
@has_ssh = false if @has_ssh == UNSET_VALUE
|
||||||
@image = nil if @image == UNSET_VALUE
|
@image = nil if @image == UNSET_VALUE
|
||||||
@name = nil if @name == UNSET_VALUE
|
@name = nil if @name == UNSET_VALUE
|
||||||
|
@pull = false if @pull == UNSET_VALUE
|
||||||
@ports = [] if @ports == UNSET_VALUE
|
@ports = [] if @ports == UNSET_VALUE
|
||||||
@privileged = false if @privileged == UNSET_VALUE
|
@privileged = false if @privileged == UNSET_VALUE
|
||||||
@remains_running = true if @remains_running == UNSET_VALUE
|
@remains_running = true if @remains_running == UNSET_VALUE
|
||||||
|
|
|
@ -60,6 +60,9 @@ General settings:
|
||||||
across all containers on the host VM. By default Vagrant will generate
|
across all containers on the host VM. By default Vagrant will generate
|
||||||
some random name.
|
some random name.
|
||||||
|
|
||||||
|
* `pull` (bool) - If true, the image will be pulled on every `up` and
|
||||||
|
`reload`. Defaults to false.
|
||||||
|
|
||||||
* `ports` (array of strings) - Ports to expose from the container to the
|
* `ports` (array of strings) - Ports to expose from the container to the
|
||||||
host. These should be in the format of `host:container`.
|
host. These should be in the format of `host:container`.
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue