Skip to content
This repository has been archived by the owner on Aug 1, 2023. It is now read-only.

lucli update --images #6

Open
lucymhdavies opened this issue Apr 7, 2018 · 0 comments
Open

lucli update --images #6

lucymhdavies opened this issue Apr 7, 2018 · 0 comments

Comments

@lucymhdavies
Copy link
Collaborator

Borrow from staticli

https://github.com/staticli/staticli/blob/master/cmd/update.go#L18-L32

Need a mechanism to ensure that any images cloned are up-to-date.

I kinda want this to be default behaviour, which would mean an optional override on Cali

https://github.com/skybet/cali/blob/master/docker.go#L193-L197

	if !c.ImageExists(c.Conf.Image){
		if err := c.PullImage(c.Conf.Image); err != nil {
			return "", fmt.Errorf("Failed to fetch image: %s", err)
		}
	}

would be something like

-	if !c.ImageExists(c.Conf.Image){
+	if !c.ImageExists(c.Conf.Image) || task.AlwaysPullImage{

In my case, task.AlwaysPullImage would be set by a flag at the root.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant