Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Empty file modified rootfs/standard/usr/bin/mynode_firewall.sh
100755 → 100644
Empty file.
Empty file modified rootfs/standard/usr/bin/mynode_update_latest_version_files.sh
100755 → 100644
Empty file.
72 changes: 72 additions & 0 deletions rootfs/standard/usr/share/mynode_apps/albyhub/albyhub.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
{
"name": "albyhub",
"short_name": "albyhub",
"author": {
"name": "getAlby",
"link": "https://www.albyhub.com"
},
"website": {
"name": "GitHub",
"link": "https://github.com/getAlby/hub"
},
"category": "lightning_app",
"short_description": "Lightning Wallet",
"description": [
"Alby Hub is a self-custodial, open source lightning wallet that connects to apps.",
"Lightning Made Easy - Running your own node has never been easier.",
"Set up your own LDK Lightning node in one click, top up channels via credit card or bank transfer,",
"choose from the most reliable liquidity providers in the space and get 24/7 live support",
"– all in one intuitive interface.",
"You will also easily understand how the lightning network works and learning effortlessly along the way."
],
"latest_version": "v1.15.0",
"supported_archs": null,
"download_skip": true,
"download_type": "source",
"download_source_url": "not_required",
"download_binary_url": {
"aarch64": "download_url",
"x86_64": "download_url"
},
"install_env_vars": {},
"supports_app_page": true,
"supports_testnet": false,
"http_port": 8080,
"https_port": 8081,
"requires_bitcoin": false,
"requires_docker_image_installation": true,
"requires_electrs": false,
"requires_lightning": false,
"show_on_application_page": true,
"show_on_homepage": true,
"show_on_status_page": true,
"hide_status_icon": false,
"app_tile_name": "albyhub",
"app_tile_running_status_text": "Running",
"app_tile_button_text": "Info",
"app_tile_button_href": "/app/albyhub/info",
"app_page_show_open_button": true,
"app_page_content": [
{
"heading": "Instructions",
"content": [
"Alby Hub - Your Own Center for Internet Money",
"On first login non-recoverable password will be created.",
"Configuration with LDK will create non-custodial Lightning Node.",
"Lightning node uses external services for Bitcoin Blockchain data and indexes. So disk space usage of Alby Hub is minimal.",
"Make sure you have backups https://guides.getalby.com/user-guide/alby-account-and-browser-extension/alby-hub/backups-and-recover",
"You can open the app with the Open button on the left.",
"Enjoy!"
]
}
],
"can_uninstall": true,
"can_reinstall": true,
"can_enable_disable": true,
"is_beta": false,
"is_premium": false,
"homepage_section": "apps",
"homepage_order": 91,
"app_type": "custom",
"sdk_version": 2
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
32 changes: 32 additions & 0 deletions rootfs/standard/usr/share/mynode_apps/albyhub/albyhub.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# albyhub service
# /etc/systemd/system/albyhub.service

[Unit]
Description=albyhub
Wants=www.service docker_images.service
After=www.service docker_images.service

[Service]
WorkingDirectory=/opt/mynode/albyhub

ExecStartPre=/usr/bin/is_not_shutting_down.sh
ExecStartPre=/bin/bash -c 'if [ -f /usr/bin/service_scripts/pre_albyhub.sh ]; then /bin/bash /usr/bin/service_scripts/pre_albyhub.sh; fi'
ExecStart=docker run --rm \
--name albyhub \
--publish 8080:8080 \
--volume /mnt/hdd/mynode/albyhub:/data \
--env WORK_DIR='/data' \
albyhub
ExecStartPost=/bin/bash -c 'if [ -f /usr/bin/service_scripts/post_albyhub.sh ]; then /bin/bash /usr/bin/service_scripts/post_albyhub.sh; fi'
ExecStop=docker stop -t 2 albyhub

User=bitcoin
Group=bitcoin
Type=simple
TimeoutSec=120
Restart=always
RestartSec=60
SyslogIdentifier=albyhub

[Install]
WantedBy=multi-user.target
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
server {
listen 8081 ssl;
server_name albyhub;

include /etc/nginx/mynode/mynode_ssl_params.conf;
include /etc/nginx/mynode/mynode_ssl_cert_key.conf;

access_log /var/log/nginx/access_albyhub.log;
error_log /var/log/nginx/error_albyhub.log;

location / {
proxy_pass http://127.0.0.1:8080;

include /etc/nginx/mynode/mynode_ssl_proxy_params.conf;
}

}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#!/bin/bash

source /usr/share/mynode/mynode_device_info.sh
source /usr/share/mynode/mynode_app_versions.sh

set -x
set -e

echo "==================== INSTALLING APP ===================="

# The current directory is the app install folder and the app tarball from GitHub
# has already been downloaded and extracted. Any additional env variables specified
# in the JSON file are also present.

#echo "DOCKER NAME: $DOCKER_IMAGE_NAME"
#echo "VERSION: $VERSION"

# Make dir that is used as .service Workdirectory if not exist
mkdir -p /opt/mynode/albyhub || true
# Make dir that will be volume mounted to the container if not exist
mkdir -p /mnt/hdd/mynode/albyhub || true
# no backup / restore implemented

# Clear any old images, only if they exist
docker images --format '{{.Repository}}:{{.Tag}}' | grep 'albyhub' | xargs --no-run-if-empty docker rmi
docker images --format '{{.Repository}}:{{.Tag}}' | grep 'ghcr.io/getalby/hub' | xargs --no-run-if-empty docker rmi

# Pull ready dockers, instead of source
docker pull ghcr.io/getalby/hub:$ALBYHUB_VERSION
docker tag ghcr.io/getalby/hub:$ALBYHUB_VERSION albyhub

echo "================== DONE INSTALLING APP ================="
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/bash

# This will run after launching the application
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/bash

# This will run prior to launching the application
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/bash

source /usr/share/mynode/mynode_device_info.sh
source /usr/share/mynode/mynode_app_versions.sh

echo "==================== UNINSTALLING APP ===================="

# The app folder will be removed automatically after this script runs. You may not need to do anything here.

# Clear any old images, only if they exist
docker images --format '{{.Repository}}:{{.Tag}}' | grep 'albyhub' | xargs --no-run-if-empty docker rmi
docker images --format '{{.Repository}}:{{.Tag}}' | grep 'ghcr.io/getalby/hub' | xargs --no-run-if-empty docker rmi

# no backup / restore implemented

echo "================== DONE UNINSTALLING APP ================="
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
from flask import Blueprint, render_template, redirect
from user_management import check_logged_in
from enable_disable_functions import *
from device_info import *
from application_info import *
from systemctl_info import *
import subprocess
import os


mynode_albyhub = Blueprint('mynode_albyhub',__name__)


### Page functions (have prefix /app/<app name/)
@mynode_albyhub.route("/info")
def albyhub_page():
check_logged_in()

app = get_application("albyhub")
app_status = get_application_status("albyhub")
app_status_color = get_application_status_color("albyhub")

# Load page
templateData = {
"title": "myNode - " + app["name"],
"ui_settings": read_ui_settings(),
"app_status": app_status,
"app_status_color": app_status_color,
"app": app
}
return render_template('/app/generic_app.html', **templateData)

Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Custom Jinja templates (HTML files) can be added here for unique application pages

Templates will be available under applications/<short_name>/xyz.html