You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thus to *guarantee* a successful rollback, you have to shutdown your RPi and
52
+
save a complete disk image backup of its storage using another machine.
45
53
46
-
To ensure a successful rollback, you have to shutdown your RPi and backup a
47
-
complete image of its storage device using another machine. This will also
48
-
ensure all databases are saved in a valid state.
54
+
For a hobby project, not having perfect rollback may be a risk you're willing
55
+
to take. Usually container image problems have fixes/workarounds within a day.
49
56
50
57
## Recommended: Update only Docker images
51
58
52
59
When you built the stack using the menu, it created the Docker Compose file
53
60
`docker-compose.yml`. This file uses tag references (e.g. `:latest`) to get the
54
61
image for that tag from hub.docker.com. Thus when Docker is told to pull
55
62
images, it will download and update it's local cache to the newest image. No
56
-
need to do any updates to `docker-compose.yml`.
63
+
need to update `docker-compose.yml` or `Dockerfile`s.
57
64
58
65
Updating the IOTstack project templates and recreating your
59
66
`docker-compose.yml` isn't usually necessary. Doing so isn't likely to provide
60
67
much benefits, and may actually break something. A full update is only
61
68
recommended when there is a new feature or change you need.
62
69
63
-
!!! note "Recommended update procedure"
70
+
!!! tip "Recommended update procedure"
64
71
65
72
1. Shutdown your RPi, remove its storage medium and backup a full image
66
-
of the storage to another machine. Reinstall your storage and power up
73
+
of the storage to another machine. Reattach your storage and power up
67
74
your RPi. To skip this step may cause a long downtime as you debug the
68
75
problem.
69
76
2. Get latest images from the web:
70
-
```bash
71
-
docker-compose pull
77
+
``` console
78
+
$ docker-compose pull
72
79
```
73
80
3. Rebuild localy created images based on new parent images:
74
-
```bash
75
-
docker-compose build --pull --no-cache
81
+
``` console
82
+
$ docker-compose build --pull --no-cache
76
83
```
77
84
Note: this may not do anything, depending on your selected services.
78
-
4. Update(recreate) containers to use new images:
79
-
```bash
80
-
docker-compose up --build -d
85
+
4. Update(recreate) containers that have new images:
86
+
``` console
87
+
$ docker-compose up --build -d
81
88
```
82
89
83
90
If a service fails to start after it's updated, especially if you are updating
84
-
frequently, wait for a few hours and repeat the update procedure. Sometimes
85
-
there are bad releases published to hub.docker.com, but they are usually fixed
86
-
in under half a day. Of course you are always welcome to report the problem to
87
-
our [Discord](https://discord.gg/ZpKHnks) server. Usually someone else has
91
+
frequently, wait for a few hours and repeat the update procedure. Sometimes bad
92
+
releases are published to hub.docker.com, but they are usually fixed in under
93
+
half a day. Of course you are always welcome to report the problem to our
94
+
[Discord](https://discord.gg/ZpKHnks) server. Usually someone else has
88
95
encountered the same problem and reported the fix.
89
96
90
97
## Full update
@@ -98,7 +105,7 @@ Periodically updates are made to project which include new or modified container
98
105
2. backup your current settings: `cp docker-compose.yml docker-compose.yml.bak`
99
106
3. check `git status` for any local changes you may have made to project files, ignore any reported "Untracked files". Save and preserve your changes by doing a commit: `git commit -a -m "local customization"`. Or revert them using: `git checkout -- path/to/changed_file`.
0 commit comments