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

Update node implementations to their latest versions #1076

Merged
merged 5 commits into from
Dec 12, 2024
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
3 changes: 2 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,5 +68,6 @@
"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit"
},
"typescript.tsdk": "node_modules/typescript/lib"
"typescript.tsdk": "node_modules/typescript/lib",
"conventionalCommits.scopes": ["images"]
}
8 changes: 6 additions & 2 deletions docker/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ Replace `<version>` with the desired bitcoind version (ex: `0.18.1`)

### Tags

- `0.18.4-beta.rc2` ([lnd/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/lnd/Dockerfile))
- `0.18.4-beta.rc1` ([lnd/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/lnd/Dockerfile))
- `0.18.3-beta` ([lnd/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/lnd/Dockerfile))
- `0.18.2-beta` ([lnd/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/lnd/Dockerfile))
Expand Down Expand Up @@ -93,7 +94,7 @@ Replace `<version>` with the desired bitcoind version (ex: `0.18.1`)

```sh
$ cd lnd
$ docker buildx build --platform linux/amd64,linux/arm64 --build-arg LND_VERSION=0.18.4-beta.rc1 -t polarlightning/lnd:0.18.4-beta.rc1 --push .
$ docker buildx build --platform linux/amd64,linux/arm64 --build-arg LND_VERSION=<version> -t polarlightning/lnd:<version> --push .
```

Replace `<version>` with the desired LND version (ex: `0.7.1-beta`)
Expand All @@ -102,6 +103,7 @@ Replace `<version>` with the desired LND version (ex: `0.7.1-beta`)

### Tags

- `24.11` ([clightning/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/clightning/Dockerfile))
- `24.08.1` ([clightning/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/clightning/Dockerfile))
- `24.08` ([clightning/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/clightning/Dockerfile))
- `24.05` ([clightning/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/clightning/Dockerfile))
Expand Down Expand Up @@ -160,6 +162,7 @@ Replace `<version>` with the desired Eclair version (ex: `0.3.3`).

### Tags

- `0.5.0-rc2` ([tap/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/tapd/Dockerfile))
- `0.5.0-rc1` ([tap/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/tapd/Dockerfile))
- `0.4.1-alpha` ([tap/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/tapd/Dockerfile))
- `0.4.0-alpha` ([tap/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/tapd/Dockerfile))
Expand All @@ -184,7 +187,8 @@ Replace `<version>` with the desired Tap version (ex: `0.2.0-alpha`).

### Tags

- `0.14.0-alpha.rc1` ([tap/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/tapd/Dockerfile))
- `0.14.0-alpha.rc2` ([litd/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/litd/Dockerfile))
- `0.14.0-alpha.rc1` ([litd/Dockerfile](https://github.com/jamaljsr/polar/blob/master/docker/litd/Dockerfile))

**Building the image**

Expand Down
25 changes: 15 additions & 10 deletions docker/nodes.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
{
"version": 66,
"version": 67,
"images": {
"LND": {
"latest": "0.18.4-beta.rc1",
"latest": "0.18.4-beta.rc2",
"versions": [
"0.18.4-beta.rc2",
"0.18.4-beta.rc1",
"0.18.3-beta",
"0.18.2-beta",
Expand All @@ -14,7 +15,8 @@
"0.15.5-beta"
],
"compatibility": {
"0.18.4-beta.rc1": "27.0",
"0.18.4-beta.rc2": "28.0",
"0.18.4-beta.rc1": "28.0",
"0.18.3-beta": "27.0",
"0.18.2-beta": "27.0",
"0.18.1-beta": "27.0",
Expand All @@ -25,31 +27,33 @@
}
},
"c-lightning": {
"latest": "24.08.1",
"versions": ["24.08.1", "24.08", "24.05", "24.02.2", "23.11.2"]
"latest": "24.11",
"versions": ["24.11", "24.08.1", "24.08", "24.05", "24.02.2", "23.11.2"]
},
"eclair": {
"latest": "0.10.0",
"versions": ["0.10.0", "0.9.0", "0.8.0", "0.7.0", "0.6.2", "0.5.0"]
},
"bitcoind": {
"latest": "27.0",
"latest": "28.0",
"versions": ["28.0", "27.0", "26.0", "25.0", "24.0", "23.0", "22.0", "0.21.1"]
},
"btcd": {
"latest": "",
"versions": []
},
"tapd": {
"latest": "0.5.0-rc1",
"latest": "0.5.0-rc2",
"versions": [
"0.5.0-rc2",
"0.5.0-rc1",
"0.4.1-alpha",
"0.4.0-alpha",
"0.3.3-alpha",
"0.3.2-alpha"
],
"compatibility": {
"0.5.0-rc2": "0.18.4-beta.rc2",
"0.5.0-rc1": "0.18.4-beta.rc1",
"0.4.1-alpha": "0.18.0-beta",
"0.4.0-alpha": "0.18.0-beta",
Expand All @@ -58,10 +62,11 @@
}
},
"litd": {
"latest": "0.14.0-alpha.rc1",
"versions": ["0.14.0-alpha.rc1"],
"latest": "0.14.0-alpha.rc2",
"versions": ["0.14.0-alpha.rc2", "0.14.0-alpha.rc1"],
"compatibility": {
"0.14.0-alpha.rc1": "27.0"
"0.14.0-alpha.rc2": "28.0",
"0.14.0-alpha.rc1": "28.0"
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/store/models/designer.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -627,7 +627,7 @@ describe('Designer model', () => {
expect.objectContaining({
message: 'Failed to add node',
error: new Error(
'This network does not contain a LND v0.18.4-beta.rc1 (or higher) ' +
'This network does not contain a LND v0.18.4-beta.rc2 (or higher) ' +
`node which is required for tapd v${tapdLatest}`,
),
}),
Expand Down
33 changes: 22 additions & 11 deletions src/utils/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -333,11 +333,12 @@ export const REPO_STATE_URL =
* are pushed to Docker Hub, this list should be updated along with the /docker/nodes.json file.
*/
export const defaultRepoState: DockerRepoState = {
version: 66,
version: 67,
images: {
LND: {
latest: '0.18.4-beta.rc1',
latest: '0.18.4-beta.rc2',
versions: [
'0.18.4-beta.rc2',
'0.18.4-beta.rc1',
'0.18.3-beta',
'0.18.2-beta',
Expand All @@ -350,7 +351,8 @@ export const defaultRepoState: DockerRepoState = {
// not all LND versions are compatible with all bitcoind versions.
// this mapping specifies the highest compatible bitcoind for each LND version
compatibility: {
'0.18.4-beta.rc1': '27.0',
'0.18.4-beta.rc2': '28.0',
'0.18.4-beta.rc1': '28.0',
'0.18.3-beta': '27.0',
'0.18.2-beta': '27.0',
'0.18.1-beta': '27.0',
Expand All @@ -361,27 +363,35 @@ export const defaultRepoState: DockerRepoState = {
},
},
'c-lightning': {
latest: '24.08.1',
versions: ['24.08.1', '24.08', '24.05', '24.02.2', '23.11.2'],
latest: '24.11',
versions: ['24.11', '24.08.1', '24.08', '24.05', '24.02.2', '23.11.2'],
},
eclair: {
latest: '0.10.0',
versions: ['0.10.0', '0.9.0', '0.8.0', '0.7.0', '0.6.2', '0.5.0'],
},
bitcoind: {
latest: '27.0',
latest: '28.0',
versions: ['28.0', '27.0', '26.0', '25.0', '24.0', '23.0', '22.0', '0.21.1'],
},
btcd: {
latest: '',
versions: [],
},
tapd: {
latest: '0.5.0-rc1',
versions: ['0.5.0-rc1', '0.4.1-alpha', '0.4.0-alpha', '0.3.3-alpha', '0.3.2-alpha'],
latest: '0.5.0-rc2',
versions: [
'0.5.0-rc2',
'0.5.0-rc1',
'0.4.1-alpha',
'0.4.0-alpha',
'0.3.3-alpha',
'0.3.2-alpha',
],
// Not all tapd versions are compatible with all LND versions.
// This mapping specifies the minimum compatible LND for each tapd version
compatibility: {
'0.5.0-rc2': '0.18.4-beta.rc2',
'0.5.0-rc1': '0.18.4-beta.rc1',
'0.4.1-alpha': '0.18.0-beta',
'0.4.0-alpha': '0.18.0-beta',
Expand All @@ -390,10 +400,11 @@ export const defaultRepoState: DockerRepoState = {
},
},
litd: {
latest: '0.14.0-alpha.rc1',
versions: ['0.14.0-alpha.rc1'],
latest: '0.14.0-alpha.rc2',
versions: ['0.14.0-alpha.rc2', '0.14.0-alpha.rc1'],
compatibility: {
'0.14.0-alpha.rc1': '27.0',
'0.14.0-alpha.rc2': '28.0',
'0.14.0-alpha.rc1': '28.0',
},
},
},
Expand Down
10 changes: 9 additions & 1 deletion src/utils/network.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import {
import { Network } from 'types';
import { defaultRepoState } from './constants';
import {
createBitcoindNetworkNode,
createCLightningNetworkNode,
createLitdNetworkNode,
createLndNetworkNode,
Expand Down Expand Up @@ -324,7 +325,7 @@ describe('Network Utils', () => {
it('should add a tap node linked to the exact minimum LND version', async () => {
const lnd = createLndNetworkNode(
network,
'0.18.4-beta.rc1',
'0.18.4-beta.rc2',
defaultRepoState.images.LND.compatibility,
{ image: '', command: '' },
Status.Stopped,
Expand All @@ -343,6 +344,13 @@ describe('Network Utils', () => {
});

it('should fail to create a tap node without a compatible LND version', async () => {
const btc = createBitcoindNetworkNode(
network,
'27.0',
{ image: '', command: '' },
Status.Stopped,
);
network.nodes.bitcoin.push(btc);
const lnd = createLndNetworkNode(
network,
'0.15.5-beta',
Expand Down
20 changes: 15 additions & 5 deletions src/utils/tests/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,9 @@ export const testRepoState: DockerRepoState = {
version: 50,
images: {
LND: {
latest: '0.18.4-beta.rc1',
latest: '0.18.4-beta.rc2',
versions: [
'0.18.4-beta.rc2',
'0.18.4-beta.rc1',
'0.18.3-beta',
'0.18.2-beta',
Expand Down Expand Up @@ -106,7 +107,8 @@ export const testRepoState: DockerRepoState = {
// not all LND versions are compatible with all bitcoind versions.
// this mapping specifies the highest compatible bitcoind for each LND version
compatibility: {
'0.18.4-beta.rc1': '27.0',
'0.18.4-beta.rc2': '28.0',
'0.18.4-beta.rc1': '28.0',
'0.18.3-beta': '27.0',
'0.18.2-beta': '27.0',
'0.18.1-beta': '27.0',
Expand Down Expand Up @@ -175,11 +177,19 @@ export const testRepoState: DockerRepoState = {
versions: [],
},
tapd: {
latest: '0.5.0-rc1',
versions: ['0.5.0-rc1', '0.4.1-alpha', '0.4.0-alpha', '0.3.3-alpha', '0.3.2-alpha'],
latest: '0.5.0-rc2',
versions: [
'0.5.0-rc2',
'0.5.0-rc1',
'0.4.1-alpha',
'0.4.0-alpha',
'0.3.3-alpha',
'0.3.2-alpha',
],
// Not all tapd versions are compatible with all LND versions.
// This mapping specifies the minimum compatible LND for each tapd version
compatibility: {
'0.5.0-rc2': '0.18.4-beta.rc2',
'0.5.0-rc1': '0.18.4-beta.rc1',
'0.4.1-alpha': '0.18.0-beta',
'0.4.0-alpha': '0.18.0-beta',
Expand All @@ -191,7 +201,7 @@ export const testRepoState: DockerRepoState = {
latest: '0.14.0-alpha.rc1',
versions: ['0.14.0-alpha.rc1'],
compatibility: {
'0.14.0-alpha.rc1': '27.0',
'0.14.0-alpha.rc1': '28.0',
},
},
},
Expand Down
Loading