Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gnosis #8

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
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
Binary file modified build/avatar.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions build/docker-compose-gnosis.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
version: '3.4'
services:
lighthouse-gnosis.avado.dnp.dappnode.eth:
image: 'lighthouse-gnosis.avado.dnp.dappnode.eth:0.0.1'
image: 'lighthouse-gnosis.avado.dnp.dappnode.eth:0.0.2'
build:
context: ./build
args:
VERSION: v4.6.0
VERSION: v5.0.0
NETWORK: gnosis
volumes:
- 'data:/data'
Expand Down
4 changes: 2 additions & 2 deletions build/docker-compose-holesky.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
version: '3.4'
services:
lighthouse-holesky.avado.dnp.dappnode.eth:
image: 'lighthouse-holesky.avado.dnp.dappnode.eth:0.0.1'
image: 'lighthouse-holesky.avado.dnp.dappnode.eth:0.0.3'
build:
context: ./build
args:
VERSION: v4.6.0
VERSION: v5.0.0
NETWORK: holesky
volumes:
- 'data:/data'
Expand Down
2 changes: 1 addition & 1 deletion build/docker-compose-prater.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ services:
build:
context: ./build
args:
VERSION: v4.6.0
VERSION: v5.0.0
NETWORK: prater
volumes:
- 'data:/data'
Expand Down
8 changes: 4 additions & 4 deletions build/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
version: '3.4'
services:
lighthouse-holesky.avado.dnp.dappnode.eth:
image: 'lighthouse-holesky.avado.dnp.dappnode.eth:0.0.2'
lighthouse-gnosis.avado.dnp.dappnode.eth:
image: 'lighthouse-gnosis.avado.dnp.dappnode.eth:0.0.2'
build:
context: ./build
args:
VERSION: v4.6.0
NETWORK: holesky
VERSION: v5.0.0
NETWORK: gnosis
volumes:
- 'data:/data'
environment:
Expand Down
29 changes: 28 additions & 1 deletion build/server/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,36 @@ import { Status } from "https://deno.land/x/oak_commons@0.5.0/status.ts";
import { oakCors } from "https://deno.land/x/cors/mod.ts";

import { server_config } from "./server_config.ts";
import { defaultsettings, read_settings, write_settings } from "./settings.ts";
import { SupervisorCtl } from "./supervisorctl.ts";

import defaultsettings_gnosis from "./settings/defaultsettings-gnosis.json" with { type: "json" };
import defaultsettings_holesky from "./settings/defaultsettings-holesky.json" with { type: "json" };
import defaultsettings_mainnet from "./settings/defaultsettings-mainnet.json" with { type: "json" };
import defaultsettings_prater from "./settings/defaultsettings-prater.json" with { type: "json" };

const settings_file_path = '/data/settings.json';

export const defaultsettings = () => {
switch (server_config.network) {
case "gnosis": return defaultsettings_gnosis;
case "holesky": return defaultsettings_holesky;
case "prater": return defaultsettings_prater;
default: return defaultsettings_mainnet;
}
};

export const read_settings = async () => {
const text = await Deno.readTextFile(settings_file_path);
return JSON.parse(text);
}

export const write_settings = async (settings: any) => {
console.log(settings);
console.dir(settings);
const text = JSON.stringify(settings, null, 4);
await Deno.writeTextFile(settings_file_path, text);
}

const router = new Router();

router.get('/ping', (context) => {
Expand Down
4 changes: 2 additions & 2 deletions build/server/server_config.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"network": "holesky",
"network": "gnosis",
"name": "lighthouse",
"supervisord_programs": [
"lighthouse-bn",
"lighthouse-vc"
]
}
}
29 changes: 0 additions & 29 deletions build/server/settings.ts

This file was deleted.

2 changes: 1 addition & 1 deletion build/wizard/src/server_config.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"network": "holesky",
"network": "gnosis",
"name": "lighthouse"
}
4 changes: 2 additions & 2 deletions dappnode_package-gnosis.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "lighthouse-gnosis.avado.dnp.dappnode.eth",
"version": "0.0.1",
"upstream": "v4.6.0",
"version": "0.0.2",
"upstream": "v5.0.0",
"title": "Lighthouse-Gnosis",
"description": "An open-source Ethereum consensus client, written in Rust and maintained by Sigma Prime.",
"avatar": "/ipfs/QmXimBvXWsL8xzuNoift9ygFdCHAMoj2e8vDeeMbgpX8gC",
Expand Down
4 changes: 2 additions & 2 deletions dappnode_package-holesky.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "lighthouse-holesky.avado.dnp.dappnode.eth",
"version": "0.0.1",
"upstream": "v4.6.0",
"version": "0.0.3",
"upstream": "v5.0.0",
"title": "Lighthouse Holesky Testnet",
"description": "An open-source Ethereum consensus client, written in Rust and maintained by Sigma Prime.",
"avatar": "/ipfs/QmTfWJzXCZF9x9sWkok55JMci9mBBfQambku8bvh6Lnwrh",
Expand Down
2 changes: 1 addition & 1 deletion dappnode_package-prater.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "lighthouse-prater.avado.dnp.dappnode.eth",
"version": "0.0.1",
"upstream": "v4.6.0",
"upstream": "v5.0.0",
"title": "Lighthouse Goerli/Prater Testnet",
"description": "An open-source Ethereum consensus client, written in Rust and maintained by Sigma Prime.",
"avatar": "/ipfs/QmNkSDpE6ZspaSamcrnsKnvmR3bbQeWQWTUjcbKwUm4AiT",
Expand Down
16 changes: 8 additions & 8 deletions dappnode_package.json
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
{
"name": "lighthouse-holesky.avado.dnp.dappnode.eth",
"name": "lighthouse-gnosis.avado.dnp.dappnode.eth",
"version": "0.0.2",
"upstream": "v4.6.0",
"title": "Lighthouse Holesky Testnet",
"upstream": "v5.0.0",
"title": "Lighthouse-Gnosis",
"description": "An open-source Ethereum consensus client, written in Rust and maintained by Sigma Prime.",
"avatar": "/ipfs/QmTfWJzXCZF9x9sWkok55JMci9mBBfQambku8bvh6Lnwrh",
"avatar": "/ipfs/QmXimBvXWsL8xzuNoift9ygFdCHAMoj2e8vDeeMbgpX8gC",
"type": "service",
"autoupdate": true,
"image": {
"volumes": [
"data:/data"
],
"ports": [
"9003:9003/udp",
"9003:9003"
"9011:9011/udp",
"9011:9011"
],
"environment": [
"EXTRA_OPTS_BEACON_NODE=",
Expand All @@ -26,12 +26,12 @@
"dependencies": {},
"ui": {
"OnboardingWizard": {
"url": "http://lighthouse-holesky.my.ava.do",
"url": "http://lighthouse-gnosis.my.ava.do",
"external": true
}
},
"links": {
"OnboardingWizard": "http://lighthouse-holesky.my.ava.do",
"OnboardingWizard": "http://lighthouse-gnosis.my.ava.do",
"HomePage": "https://lighthouse-book.sigmaprime.io/"
}
}
Loading