diff --git a/build.sbt b/build.sbt index 052efa7d2ef..b78dded33dd 100755 --- a/build.sbt +++ b/build.sbt @@ -6,7 +6,7 @@ enablePlugins(sbtdocker.DockerPlugin, JavaServerAppPackaging, JDebPackaging, Sys name := "waves" organization := "com.wavesplatform" -version := "0.7.5" +version := "0.7.7-SNAPSHOT" scalaVersion in ThisBuild := "2.12.3" crossPaths := false publishArtifact in (Compile, packageDoc) := false diff --git a/src/package/debian/postrm b/src/package/debian/postrm index 033a2b30203..48775f45ea4 100644 --- a/src/package/debian/postrm +++ b/src/package/debian/postrm @@ -6,7 +6,6 @@ if [ "$1" = purge ]; then rm -rf /var/lib/${{app_name}}/snapshots rm -rf /var/lib/${{app_name}}/data rm -rf /etc/${{app_name}}/application.ini - rm -rf /etc/${{app_name}}.conf rm -rf /var/log/${{app_name}} if is_upstart; then diff --git a/src/package/debian/preinst b/src/package/debian/preinst index 293979f5c24..79b5950592a 100644 --- a/src/package/debian/preinst +++ b/src/package/debian/preinst @@ -2,35 +2,31 @@ ${{header}} ${{loader-functions}} if [ "$1" = upgrade ]; then - # change home directory and remove legacy data files - previous_home=$(getent passwd ${{app_name}} | cut -d: -f6) - if [ "$previous_home" = /home/${{app_name}} ]; then - usermod --home /var/lib/${{app_name}} ${{app_name}} - fi - rm -f /home/${{app_name}}/waves/data/blockchain.dat - rm -f /home/${{app_name}}/waves/data/peers.dat - - # delete legacy configuration files - for file_to_remove in application.conf application-dev.conf logback-to-file.xml logback.xml reference.conf logback-overrides.xml - do - rm -f /usr/share/${{app_name}}/conf/$file_to_remove - done - - rm -fr /usr/share/${{app_name}}/conf/target rm -f /etc/init/${{app_name}}.conf - chmod -s -x /usr/share/${{app_name}}/conf/* || true - - mkdir -p /var/lib/${{app_name}} - # move wallet file to a new default location - if [ -f /home/${{app_name}}/waves/wallet/wallet.s.dat ]; then - echo Moving wallet file to a new default location ... - mkdir -p /var/lib/${{app_name}}/wallet/ - mv /home/${{app_name}}/waves/wallet/wallet.s.dat /var/lib/${{app_name}}/wallet/wallet.dat - fi - case "$2" in 0.6*) + # change home directory and remove legacy data files + rm -f /home/${{app_name}}/waves/data/blockchain.dat + rm -f /home/${{app_name}}/waves/data/peers.dat + + # delete legacy configuration files + for file_to_remove in application.conf application-dev.conf logback-to-file.xml logback.xml reference.conf logback-overrides.xml + do + rm -f /usr/share/${{app_name}}/conf/$file_to_remove + done + + rm -fr /usr/share/${{app_name}}/conf/target + + chmod -s -x /usr/share/${{app_name}}/conf/* || true + + # move wallet file to a new default location + if [ -f /home/${{app_name}}/waves/wallet/wallet.s.dat ]; then + echo Moving wallet file to a new default location ... + mkdir -p /var/lib/${{app_name}}/wallet/ + mv /home/${{app_name}}/waves/wallet/wallet.s.dat /var/lib/${{app_name}}/wallet/wallet.dat + fi + if [ -f /etc/${{app_name}}.conf ]; then echo Moving node configuration file from /etc/${{app_name}}.conf to /etc/${{app_name}}/waves.conf ... mv /etc/${{app_name}}.conf /etc/${{app_name}}/waves.conf || true @@ -46,14 +42,14 @@ if [ "$1" = upgrade ]; then mv /home/${{app_name}}/waves/journal /var/lib/${{app_name}}/journal || true mv /home/${{app_name}}/waves/snapshots /var/lib/${{app_name}}/snapshots || true fi - ;; - *) + if [ -f /etc/${{app_name}}.json ]; then echo Moving legacy configuration file to a new location ... cp /etc/${{app_name}}.json /etc/${{app_name}}/waves.json chmod -x /etc/${{app_name}}/waves.json fi - + ;; + *) rm -f /etc/${{app_name}}.json rm -f /usr/share/${{app_name}}/settings.json ;; diff --git a/waves-mainnet.conf b/waves-mainnet.conf index 5b7b8aad421..73edf13f747 100644 --- a/waves-mainnet.conf +++ b/waves-mainnet.conf @@ -14,11 +14,10 @@ waves { port = 6868 # Node name to send during handshake. Comment this string out to set random node name. - #node-name = "My MAINNET node" + # node-name = "My MAINNET node" # String with IP address and port to send as external address during handshake. Could be set automatically if uPnP is enabled. # declared-address = "1.2.3.4:6868" - } # Wallet settings