Upgrade Caravan to v0.6.2

This commit is contained in:
Taylor Helsper 2023-08-26 00:28:28 -05:00
parent c5c09722e3
commit 989c50780b
6 changed files with 47 additions and 11 deletions

View File

@ -0,0 +1,33 @@
# Serve copy of caravan files via HTTP
server {
listen 3020;
server_name caravan;
access_log /var/log/nginx/access_caravan_http.log;
error_log /var/log/nginx/error_caravan_http.log;
location / {
root /opt/mynode/caravan/build;
index index.html index.htm;
}
}
# HTTPS
server {
listen 3021 ssl;
server_name caravanhttps;
include /etc/nginx/mynode/mynode_ssl_params.conf;
include /etc/nginx/mynode/mynode_ssl_cert_key.conf;
access_log /var/log/nginx/access_caravan.log;
error_log /var/log/nginx/error_caravan.log;
location / {
proxy_pass http://127.0.0.1:3020;
proxy_read_timeout 300;
include /etc/nginx/mynode/mynode_ssl_proxy_params.conf;
}
}

View File

@ -9,9 +9,9 @@ After=bitcoin.service
[Service]
ExecStartPre=/usr/bin/is_not_shutting_down.sh
ExecStartPre=/usr/bin/wait_on_bitcoin.sh
Environment="PORT=3020 NODE_ENV=production"
WorkingDirectory=/opt/mynode/caravan
ExecStart=/usr/bin/npm start
#ExecStart=/usr/bin/npm start --port 3020 --base=/ --host
ExecStart=/usr/bin/sleep 365d
StandardInput=tty-force
TTYVHangup=yes

View File

@ -229,6 +229,7 @@ HiddenServicePort 3003 127.0.0.1:3003
HiddenServicePort 3010 127.0.0.1:3010
HiddenServicePort 3011 127.0.0.1:3011
HiddenServicePort 3020 127.0.0.1:3020
HiddenServicePort 3021 127.0.0.1:3021
HiddenServicePort 3030 127.0.0.1:3030
HiddenServicePort 3031 127.0.0.1:3031
HiddenServicePort 4080 127.0.0.1:4080

View File

@ -316,7 +316,7 @@ if ! skip_base_upgrades ; then
fi
# Update NPM (Node Package Manager)
npm install -g npm@$NODE_NPM_VERSION
#npm install -g npm@$NODE_NPM_VERSION
npm install -g yarn @quasar/cli
# Install Docker
@ -633,7 +633,7 @@ fi
# Install Caravan
if should_install_app "caravan" ; then
CARAVAN_UPGRADE_URL=https://github.com/unchained-capital/caravan/archive/$CARAVAN_VERSION.tar.gz
CARAVAN_UPGRADE_URL=https://github.com/unchained-capital/caravan/archive/caravan-$CARAVAN_VERSION.tar.gz
CURRENT=""
if [ -f $CARAVAN_VERSION_FILE ]; then
CURRENT=$(cat $CARAVAN_VERSION_FILE)
@ -650,7 +650,12 @@ if should_install_app "caravan" ; then
chown -R bitcoin:bitcoin caravan
cd caravan
sudo -u bitcoin npm install --only=production
# Change path to / from /caravan
sed -i 's|/caravan/#|/#|' vite.config.js
sudo -u bitcoin npm install
sudo -u bitcoin npm run build
echo $CARAVAN_VERSION > $CARAVAN_VERSION_FILE
touch $CARAVAN_SETTINGS_UPDATE_FILE
fi

View File

@ -7,7 +7,7 @@
$(document).ready(function() {
$("#caravan").on("click", function() {
url = 'https://'+location.hostname+':3020'
url = 'https://'+location.hostname+':3021'
window.open(url,'_blank');
})
@ -47,10 +47,7 @@
<ol class="instructions-steps">
<li>Change the Public/Private option to Private</li>
<li>Change the URL to your node's IP address: <a href="https://{{local_ip}}:8335" target="_blank">https://{{local_ip}}:8335</a></li>
<ul>
<li>You may need to visit the URL in your browser and accept the HTTPS certificate</li>
</ul>
<li>Change the URL to your node's IP address: http://{{local_ip}}:8336</li>
<li>Change the Username to "mynode"</li>
<li>Change the Password to the RPC Password from the <a href="/bitcoin">Bitcoin page</a></li>
<li>Click "Test Connection"</li>

View File

@ -75,7 +75,7 @@ def page_tor():
v3_services.append(create_v3_service("LND Hub", lndhub_onion_url, "80 / 443", True, ""))
v3_services.append(create_v3_service("BTC RPC Explorer", general_onion_url, "3002 / 3003", False, ""))
v3_services.append(create_v3_service("Ride the Lightning", general_onion_url, "3010 / 3011", True, ""))
v3_services.append(create_v3_service("Caravan", general_onion_url, "3020", True, ""))
v3_services.append(create_v3_service("Caravan", general_onion_url, "3020 / 3021", True, ""))
v3_services.append(create_v3_service("Thunderhub", general_onion_url, "3030 / 3031", True, ""))
v3_services.append(create_v3_service("Mempool", general_onion_url, "4080 / 4081", True, ""))
v3_services.append(create_v3_service("LNbits", lnbits_onion_url, "80 / 443", True, ""))