WARNING
This is only for Plume operators. Otherwise, this would be a very boring article to read and wouldn't help you very much.
Purpose
Write a guide on how to upgrade Plume from version 0.3 to 0.4 for instance owners.
My system
OS: Ubuntu 18.04
DB: PostgresSQL 12.1
Installed Plume: Binary guide here
User: plume
Install Location: /home/plume/Plume
Upgrade Guide
BACKUP!!!
- Backup Database `sudo -u postgres pg_dump plumedatabase > plumedatabase.sql
- Log in as plume user
su plume
- Backup binary
cd ~&&cp -a Plume Plume.bak
- Change directory to where plume was installed
cd ~/Plume
git pull origin master
Results in error (for me, maybe not for you):
plume@comp:~/Plume$ git pull origin master
From https://github.com/Plume-org/Plume
* branch master -> FETCH_HEAD
Updating e54fffc..5f8d6b8
error: Your local changes to the following files would be overwritten by merge:
po/plume/ar.po
po/plume/bg.po
po/plume/ca.po
po/plume/cs.po
po/plume/de.po
po/plume/en.po
po/plume/eo.po
po/plume/es.po
po/plume/fr.po
po/plume/gl.po
po/plume/hi.po
po/plume/hr.po
po/plume/it.po
po/plume/ja.po
po/plume/pl.po
po/plume/pt.po
po/plume/ro.po
po/plume/ru.po
po/plume/sk.po
po/plume/sr.po
po/plume/sv.po
Please commit your changes or stash them before you merge.
Aborting
- Clean it (will remove all local changes you have made)
git clean -f&&git clean -fd&&git reset --hard
- Then do
git pull origin master
- If you want to use latest tagged version not directly from the master branch, also do
git checkout 0.4.0-alpha-4
- Build front end
cargo web deploy -p plume-front
plume@comp:~/Plume$ cargo web deploy -p plume-front
info: syncing channel updates for 'nightly-2020-01-15-x86_64-unknown-linux-gnu'
info: latest update on 2020-01-15, rust version 1.42.0-nightly (8a87b945b 2020-01-14)
info: downloading component 'rustc'
58.6 MiB / 58.6 MiB (100 %) 23.8 MiB/s in 3s ETA: 0s
info: downloading component 'rust-std'
info: downloading component 'cargo'
info: downloading component 'rust-docs'
info: installing component 'rustc'
58.6 MiB / 58.6 MiB (100 %) 6.4 MiB/s in 9s ETA: 0s
info: installing component 'rust-std'
17.3 MiB / 17.3 MiB (100 %) 7.3 MiB/s in 1s ETA: 0s
info: installing component 'cargo'
info: installing component 'rust-docs'
12.0 MiB / 12.0 MiB (100 %) 4.3 MiB/s in 2s ETA: 0s
info: downloading component 'rust-std' for 'wasm32-unknown-unknown'
info: installing component 'rust-std' for 'wasm32-unknown-unknown'
Compiling proc-macro2 v0.4.30
Compiling unicode-xid v0.1.0
Compiling syn v0.15.34
Compiling serde v1.0.91
Compiling ryu v1.0.0
Compiling encoding_index_tests v0.1.4
Compiling semver-parser v0.7.0
Compiling stdweb-internal-runtime v0.1.4
Compiling itoa v0.4.4
Compiling byteorder v0.4.2
Compiling sha1 v0.6.0
Compiling base-x v0.2.4
Compiling spin v0.5.1
Compiling discard v1.0.4
Compiling gettext-utils v0.1.0 (https://github.com/Plume-org/gettext-macros/?rev=a7c605f7edd6bfbfbfe7778026bfefd88d82db10#a7c605f7)
Compiling encoding-index-japanese v1.20141219.5
Compiling encoding-index-korean v1.20141219.5
Compiling encoding-index-singlebyte v1.20141219.5
Compiling encoding-index-tradchinese v1.20141219.5
Compiling encoding-index-simpchinese v1.20141219.5
Compiling semver v0.9.0
Compiling lazy_static v1.4.0
Compiling encoding v0.2.33
Compiling rustc_version v0.2.3
Compiling quote v0.6.12
Compiling gettext v0.3.0 (https://github.com/Plume-org/gettext/?rev=294c54d74c699fbc66502b480a37cc66c1daa7f3#294c54d7)
Compiling stdweb v0.4.18
Compiling gettext-macros v0.4.0 (https://github.com/Plume-org/gettext-macros/?rev=a7c605f7edd6bfbfbfe7778026bfefd88d82db10#a7c605f7)
Compiling serde_derive v1.0.91
Compiling serde_json v1.0.40
Compiling stdweb-derive v0.5.1
Compiling stdweb-internal-macros v0.2.7
Compiling plume-front v0.4.0 (/home/plume/Plume/plume-front)
.... done.
.... done.
.... done.
.... done.
.... done.
.... done.
.... done.
.... done.
... done.
.... done.
... done.
... done.
... done.
... done.
.... done.
... done.
.. done.
.... done.
.... done.
... done.
.... done.
... done.
Finished dev [unoptimized + debuginfo] target(s) in 2m 22s
Processing "plume-front.wasm"...
Finished processing of "plume-front.wasm"!
The `plume-front` was deployed to "/home/plume/Plume/target/deploy"!
- Install libclang (will be required for master branch and tags > 0.5)
sudo apt install libclang-dev
- Update plm (~30 minutes)
cargo install --path plume-cli --force --features postgres
- Update plume (~ 12 minutes)
cargo install --path . --force --no-default-features --features postgres
- Run migration scripts
plm migration run
- Restart plume
sudo service plume restart
You should be up and running on Plume version 0.4! Congrats.
Comments
No comments yet. Be the first to react!