Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.
Merged

0.6.4 #148

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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ effective.pom
enforcer.pom

# db
db*
db
mainnet.log
mainnetdb
testnet.log
Expand Down
40 changes: 20 additions & 20 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
FROM helixnetwork/base16.04:latest as builder
LABEL maintainer="dt@hlx.ai"

WORKDIR /helix
COPY . /helix
WORKDIR /pendulum
COPY . /pendulum
RUN mvn clean package

FROM openjdk:jre-slim
Expand All @@ -11,27 +11,27 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
socat \
&& rm -rf /var/lib/apt/lists/*

COPY --from=builder /helix/target/helix*.jar /helix/target/
COPY --from=builder /pendulum/target/pendulum*.jar /pendulum/target/
COPY docker/entrypoint.sh /

# Default environment variables configuration. See DOCKER.md for details.
# Override these variables if required (e.g. docker run -e JAVA_OPTIONS="myoptions" ...)
# `JAVA_OPTIONS` Java related options
# `JAVA_MIN_MEMORY` and `JAVA_MAX_MEMORY` Settings for -Xms and -Xmx respectively.
# See https://docs.oracle.com/cd/E21764_01/web.1111/e13814/jvm_tuning.htm#PERFM161
# `DOCKER_HLX_JAR_PATH` Path where the HLX jar file is located.
# `DOCKER_HLX_JAR_FILE` HLX jar file.
# `DOCKER_HLX_REMOTE_LIMIT_API` Sets the --remote-limit-api options.
# `DOCKER_PLM_JAR_PATH` Path where the PLM (pendulum) jar file is located.
# `DOCKER_PLM_JAR_FILE` pendulum jar file.
# `DOCKER_PLM_REMOTE_LIMIT_API` Sets the --remote-limit-api options.
# (Deprecation warning, see https://github.com/iotaledger/iri/issues/1500)
# `DOCKER_HLX_MONITORING_API_PORT_ENABLE` When using a docker bridged network setting this to 1 will have
# `DOCKER_PLM_MONITORING_API_PORT_ENABLE` When using a docker bridged network setting this to 1 will have
# socat exposing 8086 and pointing it on localhost. See /entrypoint.sh
# Do not enable this option when running HLX's container on host network.
# Do not enable this option when running the pendulum container on host network.
# !!! DO NOT DOCKER EXPOSE (-p) 8086 as the remote api settings will
# not be applied on that port !!!
# You also have to maintain $DOCKER_HLX_MONITORING_API_PORT_DESTINATION
# based on the actual API port exposed via HLX
# `DOCKER_HLX_MONITORING_API_PORT_DESTINATION` Set this to the actual HLX API port. This is used to map port 14266.
# `DOCKER_HLX_REMOTE` When using a docker bridged network set this to true. Using host network
# You also have to maintain $DOCKER_PLM_MONITORING_API_PORT_DESTINATION
# based on the actual API port exposed via PLM
# `DOCKER_PLM_MONITORING_API_PORT_DESTINATION` Set this to the actual PLM API port. This is used to map port 14266.
# `DOCKER_PLM_REMOTE` When using a docker bridged network set this to true. Using host network
# you may choose to set it to false to make sure the API port listens on
# localhost only. If you want to bind your API (--api-host) to a specific interface
# you will have to set this option to false.
Expand All @@ -40,14 +40,14 @@ COPY docker/entrypoint.sh /
ENV JAVA_OPTIONS="-XX:+UnlockExperimentalVMOptions -XX:+DisableAttachMechanism -XX:InitiatingHeapOccupancyPercent=60 -XX:G1MaxNewSizePercent=75 -XX:MaxGCPauseMillis=10000 -XX:+UseG1GC" \
JAVA_MIN_MEMORY=2G \
JAVA_MAX_MEMORY=4G \
DOCKER_HLX_JAR_PATH="/helix/target" \
DOCKER_HLX_JAR_FILE="helix*.jar" \
DOCKER_HLX_REMOTE_LIMIT_API="interruptAttachToTangle, attachToTangle, addNeighbors, removeNeighbors, getNeighbors" \
DOCKER_HLX_MONITORING_API_PORT_ENABLE=0 \
DOCKER_HLX_MONITORING_API_PORT_DESTINATION=8085 \
DOCKER_HLX_REMOTE=true \
DOCKER_HLX_LOGGING_LEVEL="info" \
DOCKER_PLM_JAR_PATH="/pendulum/target" \
DOCKER_PLM_JAR_FILE="pendulum*.jar" \
DOCKER_PLM_REMOTE_LIMIT_API="interruptAttachToTangle, attachToTangle, addNeighbors, removeNeighbors, getNeighbors" \
DOCKER_PLM_MONITORING_API_PORT_ENABLE=0 \
DOCKER_PLM_MONITORING_API_PORT_DESTINATION=8085 \
DOCKER_PLM_REMOTE=true \
DOCKER_PLM_LOGGING_LEVEL="info" \
DOCKER_JAVA_NET_PREFER_IPV4_STACK=true

WORKDIR /helix/data
WORKDIR /pendulum/data
ENTRYPOINT [ "/entrypoint.sh" ]
29 changes: 14 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,42 +2,42 @@

[![license][4]][5] [![build][6]][7] [![grade][8]][9] [![coverage][10]][11] [![discord][14]][15]

# Helix
# Pendulum

A Quorum based Tangle implementation forked from [**IRI**](https://github.com/iotaledger/iri/).
- **Latest release:** 0.6.3 pre-release
Pendulum is a quorum based [Tangle](https://github.com/iotaledger/iri/) implementation designed towards reliable timekeeping and messaging.
- **Latest release:** 0.6.4 pre-release
- **License:** GPLv3

Special thanks to all of the [IOTA Contributors](https://github.com/iotaledger/iri/graphs/contributors)!

## Developers

- Please read [CONTRIBUTING.md](CONTRIBUTING.md) for details on our code of conduct, and the process for submitting pull requests to us.
- Please read the [helix-1.0-specifications](https://github.com/HelixNetwork/helix-specs/tree/master/specs/1.0) before contributing.
- Please read the [pendulum-1.0-specifications](https://github.com/HelixNetwork/helix-specs/tree/master/specs/1.0) before contributing.

## Installing

Make sure you have [**Maven**](https://maven.apache.org/) and [**Java 8**](https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html) installed on your computer.

### Download

$ git clone https://github.com/HelixNetwork/helix.git
$ git clone https://github.com/HelixNetwork/pendulum.git

### Build

Build an executable jar at the `target` directory using maven.

$ cd helix
$ cd pendulum
$ mvn clean package

### Launch Full node

java -jar target/helix-<VERSION>.jar -p 8085
java -jar target/pendulum-<VERSION>.jar -p 8085

### Launch Nominee node
Launching a node as a nominee first requires to generate a 64 character hex string, that is used as a seed for key generation. You will find the public key in the last line of the `nominee.key` file contained in the resources directory. If you wish to act as a nominee, please send a request to dt@hlx.ai containing your public key.

java -jar target/helix-<VERSION>.jar -p 8085 --nominee <pathToNomineeSeed>
java -jar target/pendulum-<VERSION>.jar -p 8085 --nominee <pathToNomineeSeed>


### Nginx cluster sample config
Expand All @@ -47,7 +47,7 @@ For production-level applications we recommend exposing a single public API endp
Below is a sample configuration file for the popular Nginx webserver (typically put into `/etc/nginx/conf.d/` ). For more information please consult the official Nginx [documentation](https://docs.nginx.com/nginx/admin-guide/web-server/reverse-proxy/)

```
upstream helix {
upstream pendulum {
ip_hash;
Server fullnode1.ip.address:8085;
Server fullnode2.ip.address:8085;
Expand Down Expand Up @@ -102,7 +102,7 @@ server {
proxy_set_header X-real-ip $remote_addr;
proxy_set_header X-forward-for $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_pass http://helix;
proxy_pass http://pendulum;
}
}

Expand All @@ -121,13 +121,12 @@ server {
| `--ms-delay` | `-m` | Sets delay for auto-milestones. | `-m 60` |
| `--testnet` | | Testnet flag, bypasses milestone signature validation and pow difficulty. | `--testnet` |
| `--remote` | | Remotely access your node and send API commands | `--remote` |
| `--remote-auth` | | Require authentication password for accessing remotely. Requires a correct `username:hashedpassword` combination passed to the Auth Header. | `--remote-auth helixtoken:<your_token>` |
| `--remote-auth` | | Require authentication password for accessing remotely. Requires a correct `username:hashedpassword` combination passed to the Auth Header. | `--remote-auth token:<your_token>` |
| `--remote-limit-api` | | Exclude certain API calls from being able to be accessed remotely | `--remote-limit-api "attachToTangle, addNeighbors"` |
| `--send-limit` | | Limit the outbound bandwidth consumption. Limit is set to mbit/s | `--send-limit 1.0` |
| `--max-peers` | | Limit the number of max accepted peers. Default is set to 0. | `--max-peers 8` |
| `--dns-resolution-false` | | Ignores DNS resolution refreshing | `--dns-resolution-false` |
| `--savelog-enabled` | | Writes the log to file system | `--savelog-enabled` |
| `--pow-disabled` | | Disables searching and validation of nonce. A feature for simnet. | `--pow-disabled` |
| `--savelog-enabled` | | Writes the log to file system | `--savelog-enabled` | | `--pow-disabled` |

### INI

Expand Down Expand Up @@ -179,9 +178,9 @@ Currently the following topics are covered:

[5]: LICENSE

[6]: https://travis-ci.com/HelixNetwork/helix-1.0.svg?token=iyim5S8NXU1bnHDx8VMr&branch=master
[6]: https://travis-ci.com/HelixNetwork/pendulum.svg?token=iyim5S8NXU1bnHDx8VMr&branch=master

[7]: https://travis-ci.com/HelixNetwork/helix-1.0
[7]: https://travis-ci.com/HelixNetwork/pendulum

[8]: https://api.codacy.com/project/badge/Grade/0756a1f4690c453e99da9e242695634d

Expand Down
6 changes: 3 additions & 3 deletions docker/ssl/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Helix with SSL for Docker
# Pendulum with SSL for Docker

This folder contains the files necessary to set up an IRI Docker container with an SSL certificate, using `nginx` proxy-pass to direct remote requests to IRI.

Expand All @@ -11,12 +11,12 @@ You'll need the following in order to get started:
## Getting Started
1. Clone this repository:
```
git clone https://github.com/helixnetwork/helix-1.0.git
git clone https://github.com/helixnetwork/pendulum.git
```

2. Navigate to this directory:
```
cd helix-1.0/docker/ssl
cd pendulum/docker/ssl
```

3. Run the setup script and follow the prompts:
Expand Down
6 changes: 3 additions & 3 deletions docker/ssl/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ nginx:
build: nginx-image
links:
- letsencrypt
- helix-1.0
- pendulum
environment:
- MY_DOMAIN_NAME=__DOMAIN__
ports:
Expand All @@ -22,6 +22,6 @@ letsencrypt:
- "443"
environment:
- TERM=xterm
helix-1.0:
image: helixnetwork/helix-1.0:latest
pendulum:
image: helixnetwork/node:latest
command: -p 8085
4 changes: 2 additions & 2 deletions docker/ssl/nginx-image/nginx-secure.conf
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ http {
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_pass http://helix:8085;
proxy_pass http://pendulum:8085;
}

}
Expand Down Expand Up @@ -48,7 +48,7 @@ http {
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_pass http://helix:8085;
proxy_pass http://pendulum:8085;
}
}
}
2 changes: 1 addition & 1 deletion docker/ssl/start.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env bash

set -e
echo "Setting up Let's Encrypt SSL for Helix using nginx proxy_pass"
echo "Setting up Let's Encrypt SSL for Pendulum using nginx proxy_pass"

while getopts 'e:d:t' flag; do
case "${flag}" in
Expand Down
28 changes: 14 additions & 14 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,18 @@
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>net.helix</groupId>
<artifactId>helix</artifactId>
<groupId>net.pendulum</groupId>
<artifactId>pendulum</artifactId>

<version>0.6.3</version>
<version>0.6.4</version>

<name>Helix</name>
<description>Helix Protocol</description>
<name>Pendulum</name>
<description>Pendulum Protocol</description>

<scm>
<url>https://github.com/helixnetwork/helix-1.0/</url>
<connection>scm:git:git://github.com/helixnetwork/helix-1.0.git</connection>
<developerConnection>scm:git:git@github.com/helixnetwork/helix-1.0.git</developerConnection>
<url>https://github.com/pendulumnetwork/pendulum/</url>
<connection>scm:git:git://github.com/pendulumnetwork/pendulum.git</connection>
<developerConnection>scm:git:git@github.com/pendulumnetwork/pendulum.git</developerConnection>
</scm>

<properties>
Expand Down Expand Up @@ -264,13 +264,13 @@
<goal>shade</goal>
</goals>
<configuration>
<finalName>helix-${project.version}</finalName>
<finalName>pendulum-${project.version}</finalName>
<outputDirectory>${project.basedir}/target</outputDirectory>
<!-- <mainClass>net.helix.hlx.HLX</mainClass> -->
<!-- <mainClass>net.helix.pendulum.Main</mainClass> -->
<transformers>
<transformer
implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
<mainClass>net.helix.hlx.HLX</mainClass>
<mainClass>net.helix.pendulum.Main</mainClass>
</transformer>
</transformers>
<filters>
Expand Down Expand Up @@ -446,7 +446,7 @@
<type>file</type>
<mapper>
<type>perm</type>
<prefix>/usr/share/helix/lib</prefix>
<prefix>/usr/share/pendulum/lib</prefix>
<user>loader</user>
<group>loader</group>
</mapper>
Expand All @@ -455,8 +455,8 @@
<data>
<type>link</type>
<symlink>true</symlink>
<linkName>/usr/share/helix/hlx.jar</linkName>
<linkTarget>/usr/share/helix/lib/${project.build.finalName}.jar</linkTarget>
<linkName>/usr/share/pendulum/pendulum.jar</linkName>
<linkTarget>/usr/share/pendulum/lib/${project.build.finalName}.jar</linkTarget>
</data>

<data>
Expand Down
8 changes: 0 additions & 8 deletions src/main/java/net/helix/hlx/conf/MainnetConfig.java

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
package net.helix.hlx;

import net.helix.hlx.controllers.TransactionViewModel;
import net.helix.hlx.crypto.Sha3;
import net.helix.hlx.crypto.Sponge;
import net.helix.hlx.crypto.SpongeFactory;
import net.helix.hlx.crypto.Winternitz;
import net.helix.hlx.model.Hash;
import net.helix.hlx.service.snapshot.Snapshot;
import net.helix.hlx.storage.Tangle;
import org.bouncycastle.util.encoders.Hex;
package net.helix.pendulum;

import net.helix.pendulum.controllers.TransactionViewModel;
import net.helix.pendulum.crypto.Sha3;
import net.helix.pendulum.crypto.Sponge;
import net.helix.pendulum.crypto.SpongeFactory;
import net.helix.pendulum.crypto.Winternitz;
import net.helix.pendulum.model.Hash;
import net.helix.pendulum.service.snapshot.Snapshot;
import net.helix.pendulum.storage.Tangle;

import java.util.*;

Expand Down
Loading