mirror of
https://github.com/Quackster/Havana.git
synced 2025-07-03 13:17:46 +00:00
Merge branch 'develop'
This commit is contained in:
commit
4abba6a2d1
19 changed files with 291 additions and 163 deletions
50
.github/workflows/pre-release.yml
vendored
50
.github/workflows/pre-release.yml
vendored
|
@ -14,21 +14,52 @@ jobs:
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- name: Set up JDK 11
|
- name: Set up JDK 17
|
||||||
uses: actions/setup-java@v2
|
uses: actions/setup-java@v2
|
||||||
with:
|
with:
|
||||||
java-version: 11
|
java-version: 17
|
||||||
distribution: 'adopt'
|
distribution: 'adopt'
|
||||||
cache: gradle
|
cache: gradle
|
||||||
- name: Build with Gradle
|
- name: Build distribution with Gradle
|
||||||
run: ./gradlew fatJar
|
run: ./gradlew distZip
|
||||||
|
|
||||||
|
- name: Decompress web distribution file
|
||||||
|
uses: montudor/action-zip@v1
|
||||||
|
with:
|
||||||
|
args: unzip -qq Havana-Web/build/distributions/Havana-Web.zip -d ./release
|
||||||
|
|
||||||
|
- name: Decompress server distribution file
|
||||||
|
uses: montudor/action-zip@v1
|
||||||
|
with:
|
||||||
|
args: unzip -qq Havana-Server/build/distributions/Havana-Server.zip -d ./release
|
||||||
|
|
||||||
|
- name: File release preparation
|
||||||
|
run: |
|
||||||
|
sudo rm -rf ./release/Havana-Web/bin/*
|
||||||
|
sudo rm -rf ./release/Havana-Web/bin
|
||||||
|
sudo rm -rf ./release/Havana-Server/bin/*
|
||||||
|
sudo rm -rf ./release/Havana-Server/bin
|
||||||
|
sudo mkdir ./Havana
|
||||||
|
sudo mkdir ./Havana/lib
|
||||||
|
sudo mv ./release/Havana-Web/lib/Havana-Server.jar ./Havana/Havana-Server.jar
|
||||||
|
sudo mv ./release/Havana-Web/lib/Havana-Web.jar ./Havana/Havana-Web.jar
|
||||||
|
sudo mv ./release/Havana-Web/lib/* ./Havana/lib
|
||||||
|
sudo mv ./release/Havana-Server/lib/* ./Havana/lib
|
||||||
|
sudo cp tools/scripts/run_server.bat ./Havana/
|
||||||
|
sudo cp tools/scripts/run_server.sh ./Havana/
|
||||||
|
sudo cp tools/scripts/run_web.bat ./Havana/
|
||||||
|
sudo cp tools/scripts/run_web.sh ./Havana/
|
||||||
|
sudo cp tools/scripts/README.txt ./Havana/
|
||||||
|
|
||||||
- id: sha-short
|
- id: sha-short
|
||||||
name: Get short SHA
|
name: Get short SHA
|
||||||
run: echo "::set-output name=sha-short::$(git rev-parse --short HEAD)"
|
run: echo "::set-output name=sha-short::$(git rev-parse --short HEAD)"
|
||||||
- name: Rename server jar file
|
|
||||||
run: cp Havana-Server/build/libs/Havana-Server-all.jar Havana-Server-${{ steps.sha-short.outputs.sha-short }}.jar
|
- name: Compress release files
|
||||||
- name: Rename web jar file
|
uses: montudor/action-zip@v1
|
||||||
run: cp Havana-Web/build/libs/Havana-Web-all.jar Havana-Web-${{ steps.sha-short.outputs.sha-short }}.jar
|
with:
|
||||||
|
args: zip -qq -r ./Havana-${{ steps.sha-short.outputs.sha-short }}.zip ./Havana
|
||||||
|
|
||||||
- uses: "marvinpinto/action-automatic-releases@latest"
|
- uses: "marvinpinto/action-automatic-releases@latest"
|
||||||
with:
|
with:
|
||||||
repo_token: "${{ secrets.GITHUB_TOKEN }}"
|
repo_token: "${{ secrets.GITHUB_TOKEN }}"
|
||||||
|
@ -36,5 +67,4 @@ jobs:
|
||||||
prerelease: true
|
prerelease: true
|
||||||
title: "Development Build ${{ steps.sha-short.outputs.sha-short }}"
|
title: "Development Build ${{ steps.sha-short.outputs.sha-short }}"
|
||||||
files: |
|
files: |
|
||||||
Havana-Server-${{ steps.sha-short.outputs.sha-short }}.jar
|
Havana-${{ steps.sha-short.outputs.sha-short }}.zip
|
||||||
Havana-Web-${{ steps.sha-short.outputs.sha-short }}.jar
|
|
|
@ -2,8 +2,8 @@ apply plugin: 'java'
|
||||||
apply plugin: 'application'
|
apply plugin: 'application'
|
||||||
|
|
||||||
java {
|
java {
|
||||||
sourceCompatibility = JavaVersion.toVersion("1.11")
|
sourceCompatibility = JavaVersion.toVersion("1.17")
|
||||||
targetCompatibility = JavaVersion.toVersion("1.11")
|
targetCompatibility = JavaVersion.toVersion("1.17")
|
||||||
}
|
}
|
||||||
|
|
||||||
mainClassName = 'org.alexdev.havana.Havana'
|
mainClassName = 'org.alexdev.havana.Havana'
|
||||||
|
@ -14,9 +14,6 @@ repositories {
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
// https://mvnrepository.com/artifact/net.dv8tion/JDA
|
|
||||||
implementation 'net.dv8tion:JDA:5.0.0-alpha.12'
|
|
||||||
|
|
||||||
// https://mvnrepository.com/artifact/com.zaxxer/HikariCP
|
// https://mvnrepository.com/artifact/com.zaxxer/HikariCP
|
||||||
implementation group: 'com.zaxxer', name: 'HikariCP', version: '3.4.1'
|
implementation group: 'com.zaxxer', name: 'HikariCP', version: '3.4.1'
|
||||||
|
|
||||||
|
@ -50,10 +47,14 @@ dependencies {
|
||||||
// https://mvnrepository.com/artifact/com.google.code.gson/gson
|
// https://mvnrepository.com/artifact/com.google.code.gson/gson
|
||||||
implementation group: 'com.google.code.gson', name: 'gson', version: '2.8.0'
|
implementation group: 'com.google.code.gson', name: 'gson', version: '2.8.0'
|
||||||
|
|
||||||
|
// https://mvnrepository.com/artifact/org.springframework.security/spring-security-crypto
|
||||||
|
implementation group: 'org.springframework.security', name: 'spring-security-crypto', version: '5.7.3'
|
||||||
|
|
||||||
|
// https://mvnrepository.com/artifact/org.bouncycastle/bcprov-jdk15on
|
||||||
|
implementation group: 'org.bouncycastle', name: 'bcprov-jdk15on', version: '1.70'
|
||||||
|
|
||||||
implementation 'com.maxmind.geoip2:geoip2:2.12.0'
|
implementation 'com.maxmind.geoip2:geoip2:2.12.0'
|
||||||
implementation 'com.github.bhlangonijr:chesslib:1.1.1'
|
implementation 'com.github.bhlangonijr:chesslib:1.1.1'
|
||||||
implementation 'com.goterl:lazysodium-java:5.0.1'
|
|
||||||
implementation "net.java.dev.jna:jna:5.8.0"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Create fat jar with libraries inside of it.
|
// Create fat jar with libraries inside of it.
|
||||||
|
|
|
@ -39,6 +39,7 @@ import org.alexdev.havana.util.config.writer.DefaultConfigWriter;
|
||||||
import org.alexdev.havana.util.config.writer.GameConfigWriter;
|
import org.alexdev.havana.util.config.writer.GameConfigWriter;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
import org.springframework.security.crypto.argon2.Argon2PasswordEncoder;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.net.UnknownHostException;
|
import java.net.UnknownHostException;
|
||||||
|
@ -353,4 +354,14 @@ public class Havana {
|
||||||
public static Gson getGson() {
|
public static Gson getGson() {
|
||||||
return gson;
|
return gson;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the Argon2 password encoder instance.
|
||||||
|
*
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public static Argon2PasswordEncoder getPasswordEncoder() {
|
||||||
|
var encoder =new Argon2PasswordEncoder(16, 32, 1, 65536, 2);
|
||||||
|
return encoder;
|
||||||
|
}
|
||||||
}
|
}
|
|
@ -1,11 +1,9 @@
|
||||||
package org.alexdev.havana.dao.mysql;
|
package org.alexdev.havana.dao.mysql;
|
||||||
|
|
||||||
import com.goterl.lazysodium.LazySodiumJava;
|
|
||||||
import com.goterl.lazysodium.SodiumJava;
|
|
||||||
import com.goterl.lazysodium.interfaces.PwHash;
|
|
||||||
import org.alexdev.havana.dao.Storage;
|
import org.alexdev.havana.dao.Storage;
|
||||||
import org.alexdev.havana.game.player.Player;
|
import org.alexdev.havana.game.player.Player;
|
||||||
import org.alexdev.havana.game.player.PlayerDetails;
|
import org.alexdev.havana.game.player.PlayerDetails;
|
||||||
|
import org.alexdev.havana.game.player.PlayerManager;
|
||||||
import org.alexdev.havana.util.DateUtil;
|
import org.alexdev.havana.util.DateUtil;
|
||||||
|
|
||||||
import java.nio.charset.StandardCharsets;
|
import java.nio.charset.StandardCharsets;
|
||||||
|
@ -15,7 +13,6 @@ import java.util.List;
|
||||||
import java.util.concurrent.TimeUnit;
|
import java.util.concurrent.TimeUnit;
|
||||||
|
|
||||||
public class PlayerDao {
|
public class PlayerDao {
|
||||||
public static final LazySodiumJava LIB_SODIUM = new LazySodiumJava(new SodiumJava());
|
|
||||||
private static String figureBlacklist1 = "hd-180-1.hr-100-61.ch-210-66.lg-270-82.sh-290-80";
|
private static String figureBlacklist1 = "hd-180-1.hr-100-61.ch-210-66.lg-270-82.sh-290-80";
|
||||||
|
|
||||||
public static void resetOnline() {
|
public static void resetOnline() {
|
||||||
|
@ -353,13 +350,10 @@ public class PlayerDao {
|
||||||
resultSet = preparedStatement.executeQuery();
|
resultSet = preparedStatement.executeQuery();
|
||||||
|
|
||||||
if (resultSet.next()) {
|
if (resultSet.next()) {
|
||||||
byte[] hashedPassword = (resultSet.getString("password") + '\0').getBytes(StandardCharsets.UTF_8);
|
String databasePassword = resultSet.getString("password");
|
||||||
byte[] pass = password.getBytes(StandardCharsets.UTF_8);
|
|
||||||
|
|
||||||
success = ((PwHash.Native) LIB_SODIUM).cryptoPwHashStrVerify(hashedPassword, pass, pass.length);
|
if (PlayerManager.getInstance().passwordMatches(databasePassword, password)) {
|
||||||
|
success = true;
|
||||||
if (success) {
|
|
||||||
fill(playerDetails, resultSet);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1010,23 +1004,4 @@ public class PlayerDao {
|
||||||
row.getLong("totem_effect_expiry"), row.getLong("trade_ban_expiration"), row.getInt("favourite_group"),
|
row.getLong("totem_effect_expiry"), row.getLong("trade_ban_expiration"), row.getInt("favourite_group"),
|
||||||
row.getString("created_at"));
|
row.getString("created_at"));
|
||||||
}
|
}
|
||||||
|
|
||||||
public static String createPassword(String password) throws Exception {
|
|
||||||
byte[] pw = password.getBytes();
|
|
||||||
byte[] outputHash = new byte[PwHash.STR_BYTES];
|
|
||||||
PwHash.Native pwHash = (PwHash.Native) PlayerDao.LIB_SODIUM;
|
|
||||||
boolean success = pwHash.cryptoPwHashStr(
|
|
||||||
outputHash,
|
|
||||||
pw,
|
|
||||||
pw.length,
|
|
||||||
PwHash.OPSLIMIT_INTERACTIVE,
|
|
||||||
PwHash.MEMLIMIT_INTERACTIVE
|
|
||||||
);
|
|
||||||
|
|
||||||
if (!success) {
|
|
||||||
throw new Exception("Password creation was a failure!");
|
|
||||||
}
|
|
||||||
|
|
||||||
return new String(outputHash).replace((char)0 + "", "");
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,6 +6,7 @@ import org.alexdev.havana.game.entity.Entity;
|
||||||
import org.alexdev.havana.game.entity.EntityType;
|
import org.alexdev.havana.game.entity.EntityType;
|
||||||
import org.alexdev.havana.game.player.Player;
|
import org.alexdev.havana.game.player.Player;
|
||||||
import org.alexdev.havana.game.player.PlayerDetails;
|
import org.alexdev.havana.game.player.PlayerDetails;
|
||||||
|
import org.alexdev.havana.game.player.PlayerManager;
|
||||||
import org.alexdev.havana.game.player.PlayerRank;
|
import org.alexdev.havana.game.player.PlayerRank;
|
||||||
import org.alexdev.havana.messages.outgoing.alerts.ALERT;
|
import org.alexdev.havana.messages.outgoing.alerts.ALERT;
|
||||||
|
|
||||||
|
@ -40,7 +41,7 @@ public class RecoverAccountCommand extends Command {
|
||||||
}
|
}
|
||||||
|
|
||||||
player.send(new ALERT(targetUser.getName() + "'s password has been reset to: changeme123"));
|
player.send(new ALERT(targetUser.getName() + "'s password has been reset to: changeme123"));
|
||||||
PlayerDao.setPassword(targetUser.getId(), PlayerDao.createPassword("changeme123"));
|
PlayerDao.setPassword(targetUser.getId(), PlayerManager.getInstance().createPassword("changeme123"));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
package org.alexdev.havana.game.player;
|
package org.alexdev.havana.game.player;
|
||||||
|
|
||||||
|
import org.alexdev.havana.Havana;
|
||||||
import org.alexdev.havana.dao.mysql.PlayerDao;
|
import org.alexdev.havana.dao.mysql.PlayerDao;
|
||||||
import org.alexdev.havana.game.GameScheduler;
|
import org.alexdev.havana.game.GameScheduler;
|
||||||
import org.alexdev.havana.game.player.statistics.PlayerStatistic;
|
import org.alexdev.havana.game.player.statistics.PlayerStatistic;
|
||||||
|
@ -283,6 +284,26 @@ public class PlayerManager {
|
||||||
return activePlayers;
|
return activePlayers;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Create password hash
|
||||||
|
*
|
||||||
|
* @param password password to hash
|
||||||
|
* @return hashed password
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
public String createPassword(String password) {
|
||||||
|
return Havana.getPasswordEncoder().encode(password);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get whether the hash matches the entered password.
|
||||||
|
*
|
||||||
|
* @return true, if success
|
||||||
|
*/
|
||||||
|
public boolean passwordMatches(String databasePassword, String enteredPassword) {
|
||||||
|
return Havana.getPasswordEncoder().matches(enteredPassword, databasePassword);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get daily player peak
|
* Get daily player peak
|
||||||
*
|
*
|
||||||
|
|
|
@ -2,8 +2,8 @@ apply plugin: 'java'
|
||||||
apply plugin: 'application'
|
apply plugin: 'application'
|
||||||
|
|
||||||
java {
|
java {
|
||||||
sourceCompatibility = JavaVersion.toVersion("1.11")
|
sourceCompatibility = JavaVersion.toVersion("1.17")
|
||||||
targetCompatibility = JavaVersion.toVersion("1.11")
|
targetCompatibility = JavaVersion.toVersion("1.17")
|
||||||
}
|
}
|
||||||
|
|
||||||
mainClassName = 'org.alexdev.http.HavanaWeb'
|
mainClassName = 'org.alexdev.http.HavanaWeb'
|
||||||
|
|
|
@ -9,6 +9,7 @@ import org.alexdev.havana.dao.mysql.PlayerStatisticsDao;
|
||||||
import org.alexdev.havana.dao.mysql.WardrobeDao;
|
import org.alexdev.havana.dao.mysql.WardrobeDao;
|
||||||
import org.alexdev.havana.game.misc.figure.FigureManager;
|
import org.alexdev.havana.game.misc.figure.FigureManager;
|
||||||
import org.alexdev.havana.game.player.PlayerDetails;
|
import org.alexdev.havana.game.player.PlayerDetails;
|
||||||
|
import org.alexdev.havana.game.player.PlayerManager;
|
||||||
import org.alexdev.havana.game.player.Wardrobe;
|
import org.alexdev.havana.game.player.Wardrobe;
|
||||||
import org.alexdev.havana.game.player.statistics.PlayerStatistic;
|
import org.alexdev.havana.game.player.statistics.PlayerStatistic;
|
||||||
import org.alexdev.havana.game.player.statistics.PlayerStatisticManager;
|
import org.alexdev.havana.game.player.statistics.PlayerStatisticManager;
|
||||||
|
@ -229,7 +230,7 @@ public class ProfileController {
|
||||||
webConnection.session().set("alertMessage", "Your password has been changed successfully. You will need to login again.");
|
webConnection.session().set("alertMessage", "Your password has been changed successfully. You will need to login again.");
|
||||||
webConnection.session().set("alertColour", "green");
|
webConnection.session().set("alertColour", "green");
|
||||||
|
|
||||||
PlayerDao.setPassword(playerDetails.getId(), PlayerDao.createPassword(newPassword));
|
PlayerDao.setPassword(playerDetails.getId(), PlayerManager.getInstance().createPassword(newPassword));
|
||||||
logout = true;
|
logout = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,6 +4,7 @@ import org.alexdev.duckhttpd.server.connection.WebConnection;
|
||||||
import org.alexdev.havana.dao.mysql.PlayerDao;
|
import org.alexdev.havana.dao.mysql.PlayerDao;
|
||||||
import org.alexdev.havana.dao.mysql.PlayerStatisticsDao;
|
import org.alexdev.havana.dao.mysql.PlayerStatisticsDao;
|
||||||
import org.alexdev.havana.game.player.PlayerDetails;
|
import org.alexdev.havana.game.player.PlayerDetails;
|
||||||
|
import org.alexdev.havana.game.player.PlayerManager;
|
||||||
import org.alexdev.havana.game.player.statistics.PlayerStatistic;
|
import org.alexdev.havana.game.player.statistics.PlayerStatistic;
|
||||||
import org.alexdev.havana.util.DateUtil;
|
import org.alexdev.havana.util.DateUtil;
|
||||||
import org.alexdev.havana.util.config.GameConfiguration;
|
import org.alexdev.havana.util.config.GameConfiguration;
|
||||||
|
@ -137,7 +138,7 @@ public class RecoveryController {
|
||||||
webConnection.session().set("alertMessage", "Your password has been changed successfully.");
|
webConnection.session().set("alertMessage", "Your password has been changed successfully.");
|
||||||
webConnection.session().set("alertColour", "green");
|
webConnection.session().set("alertColour", "green");
|
||||||
|
|
||||||
PlayerDao.setPassword(userId, PlayerDao.createPassword(newPassword));
|
PlayerDao.setPassword(userId, PlayerManager.getInstance().createPassword(newPassword));
|
||||||
EmailDao.removeRecoveryCode(userId);
|
EmailDao.removeRecoveryCode(userId);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,6 +9,7 @@ import org.alexdev.havana.dao.mysql.PlayerDao;
|
||||||
import org.alexdev.havana.dao.mysql.PlayerStatisticsDao;
|
import org.alexdev.havana.dao.mysql.PlayerStatisticsDao;
|
||||||
import org.alexdev.havana.dao.mysql.ReferredDao;
|
import org.alexdev.havana.dao.mysql.ReferredDao;
|
||||||
import org.alexdev.havana.game.misc.figure.FigureManager;
|
import org.alexdev.havana.game.misc.figure.FigureManager;
|
||||||
|
import org.alexdev.havana.game.player.PlayerManager;
|
||||||
import org.alexdev.havana.util.DateUtil;
|
import org.alexdev.havana.util.DateUtil;
|
||||||
import org.alexdev.havana.util.FigureUtil;
|
import org.alexdev.havana.util.FigureUtil;
|
||||||
import org.alexdev.havana.util.config.GameConfiguration;
|
import org.alexdev.havana.util.config.GameConfiguration;
|
||||||
|
@ -158,7 +159,7 @@ public class RegisterController {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
String hashedPassword = PlayerDao.createPassword(webConnection.session().getString("registerPassword"));
|
String hashedPassword = PlayerManager.getInstance().createPassword(webConnection.session().getString("registerPassword"));
|
||||||
int userId = RegisterDao.newUser(
|
int userId = RegisterDao.newUser(
|
||||||
webConnection.session().getString("registerUsername"),
|
webConnection.session().getString("registerUsername"),
|
||||||
hashedPassword,
|
hashedPassword,
|
||||||
|
|
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
Binary file not shown.
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
|
@ -1,5 +1,5 @@
|
||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.1-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-bin.zip
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
|
|
269
gradlew
vendored
269
gradlew
vendored
|
@ -1,7 +1,7 @@
|
||||||
#!/usr/bin/env sh
|
#!/bin/sh
|
||||||
|
|
||||||
#
|
#
|
||||||
# Copyright 2015 the original author or authors.
|
# Copyright © 2015-2021 the original authors.
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
|
@ -17,67 +17,101 @@
|
||||||
#
|
#
|
||||||
|
|
||||||
##############################################################################
|
##############################################################################
|
||||||
##
|
#
|
||||||
## Gradle start up script for UN*X
|
# Gradle start up script for POSIX generated by Gradle.
|
||||||
##
|
#
|
||||||
|
# Important for running:
|
||||||
|
#
|
||||||
|
# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is
|
||||||
|
# noncompliant, but you have some other compliant shell such as ksh or
|
||||||
|
# bash, then to run this script, type that shell name before the whole
|
||||||
|
# command line, like:
|
||||||
|
#
|
||||||
|
# ksh Gradle
|
||||||
|
#
|
||||||
|
# Busybox and similar reduced shells will NOT work, because this script
|
||||||
|
# requires all of these POSIX shell features:
|
||||||
|
# * functions;
|
||||||
|
# * expansions «$var», «${var}», «${var:-default}», «${var+SET}»,
|
||||||
|
# «${var#prefix}», «${var%suffix}», and «$( cmd )»;
|
||||||
|
# * compound commands having a testable exit status, especially «case»;
|
||||||
|
# * various built-in commands including «command», «set», and «ulimit».
|
||||||
|
#
|
||||||
|
# Important for patching:
|
||||||
|
#
|
||||||
|
# (2) This script targets any POSIX shell, so it avoids extensions provided
|
||||||
|
# by Bash, Ksh, etc; in particular arrays are avoided.
|
||||||
|
#
|
||||||
|
# The "traditional" practice of packing multiple parameters into a
|
||||||
|
# space-separated string is a well documented source of bugs and security
|
||||||
|
# problems, so this is (mostly) avoided, by progressively accumulating
|
||||||
|
# options in "$@", and eventually passing that to Java.
|
||||||
|
#
|
||||||
|
# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS,
|
||||||
|
# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly;
|
||||||
|
# see the in-line comments for details.
|
||||||
|
#
|
||||||
|
# There are tweaks for specific operating systems such as AIX, CygWin,
|
||||||
|
# Darwin, MinGW, and NonStop.
|
||||||
|
#
|
||||||
|
# (3) This script is generated from the Groovy template
|
||||||
|
# https://github.com/gradle/gradle/blob/master/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||||
|
# within the Gradle project.
|
||||||
|
#
|
||||||
|
# You can find Gradle at https://github.com/gradle/gradle/.
|
||||||
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
# Attempt to set APP_HOME
|
# Attempt to set APP_HOME
|
||||||
|
|
||||||
# Resolve links: $0 may be a link
|
# Resolve links: $0 may be a link
|
||||||
PRG="$0"
|
app_path=$0
|
||||||
# Need this for relative symlinks.
|
|
||||||
while [ -h "$PRG" ] ; do
|
# Need this for daisy-chained symlinks.
|
||||||
ls=`ls -ld "$PRG"`
|
while
|
||||||
link=`expr "$ls" : '.*-> \(.*\)$'`
|
APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path
|
||||||
if expr "$link" : '/.*' > /dev/null; then
|
[ -h "$app_path" ]
|
||||||
PRG="$link"
|
do
|
||||||
else
|
ls=$( ls -ld "$app_path" )
|
||||||
PRG=`dirname "$PRG"`"/$link"
|
link=${ls#*' -> '}
|
||||||
fi
|
case $link in #(
|
||||||
|
/*) app_path=$link ;; #(
|
||||||
|
*) app_path=$APP_HOME$link ;;
|
||||||
|
esac
|
||||||
done
|
done
|
||||||
SAVED="`pwd`"
|
|
||||||
cd "`dirname \"$PRG\"`/" >/dev/null
|
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
|
||||||
APP_HOME="`pwd -P`"
|
|
||||||
cd "$SAVED" >/dev/null
|
|
||||||
|
|
||||||
APP_NAME="Gradle"
|
APP_NAME="Gradle"
|
||||||
APP_BASE_NAME=`basename "$0"`
|
APP_BASE_NAME=${0##*/}
|
||||||
|
|
||||||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||||
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||||
|
|
||||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||||
MAX_FD="maximum"
|
MAX_FD=maximum
|
||||||
|
|
||||||
warn () {
|
warn () {
|
||||||
echo "$*"
|
echo "$*"
|
||||||
}
|
} >&2
|
||||||
|
|
||||||
die () {
|
die () {
|
||||||
echo
|
echo
|
||||||
echo "$*"
|
echo "$*"
|
||||||
echo
|
echo
|
||||||
exit 1
|
exit 1
|
||||||
}
|
} >&2
|
||||||
|
|
||||||
# OS specific support (must be 'true' or 'false').
|
# OS specific support (must be 'true' or 'false').
|
||||||
cygwin=false
|
cygwin=false
|
||||||
msys=false
|
msys=false
|
||||||
darwin=false
|
darwin=false
|
||||||
nonstop=false
|
nonstop=false
|
||||||
case "`uname`" in
|
case "$( uname )" in #(
|
||||||
CYGWIN* )
|
CYGWIN* ) cygwin=true ;; #(
|
||||||
cygwin=true
|
Darwin* ) darwin=true ;; #(
|
||||||
;;
|
MSYS* | MINGW* ) msys=true ;; #(
|
||||||
Darwin* )
|
NONSTOP* ) nonstop=true ;;
|
||||||
darwin=true
|
|
||||||
;;
|
|
||||||
MSYS* | MINGW* )
|
|
||||||
msys=true
|
|
||||||
;;
|
|
||||||
NONSTOP* )
|
|
||||||
nonstop=true
|
|
||||||
;;
|
|
||||||
esac
|
esac
|
||||||
|
|
||||||
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
|
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
|
||||||
|
@ -87,9 +121,9 @@ CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
|
||||||
if [ -n "$JAVA_HOME" ] ; then
|
if [ -n "$JAVA_HOME" ] ; then
|
||||||
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
||||||
# IBM's JDK on AIX uses strange locations for the executables
|
# IBM's JDK on AIX uses strange locations for the executables
|
||||||
JAVACMD="$JAVA_HOME/jre/sh/java"
|
JAVACMD=$JAVA_HOME/jre/sh/java
|
||||||
else
|
else
|
||||||
JAVACMD="$JAVA_HOME/bin/java"
|
JAVACMD=$JAVA_HOME/bin/java
|
||||||
fi
|
fi
|
||||||
if [ ! -x "$JAVACMD" ] ; then
|
if [ ! -x "$JAVACMD" ] ; then
|
||||||
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
|
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
|
||||||
|
@ -98,7 +132,7 @@ Please set the JAVA_HOME variable in your environment to match the
|
||||||
location of your Java installation."
|
location of your Java installation."
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
JAVACMD="java"
|
JAVACMD=java
|
||||||
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||||
|
|
||||||
Please set the JAVA_HOME variable in your environment to match the
|
Please set the JAVA_HOME variable in your environment to match the
|
||||||
|
@ -106,80 +140,95 @@ location of your Java installation."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Increase the maximum file descriptors if we can.
|
# Increase the maximum file descriptors if we can.
|
||||||
if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
|
if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
|
||||||
MAX_FD_LIMIT=`ulimit -H -n`
|
case $MAX_FD in #(
|
||||||
if [ $? -eq 0 ] ; then
|
max*)
|
||||||
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
|
MAX_FD=$( ulimit -H -n ) ||
|
||||||
MAX_FD="$MAX_FD_LIMIT"
|
warn "Could not query maximum file descriptor limit"
|
||||||
fi
|
esac
|
||||||
ulimit -n $MAX_FD
|
case $MAX_FD in #(
|
||||||
if [ $? -ne 0 ] ; then
|
'' | soft) :;; #(
|
||||||
warn "Could not set maximum file descriptor limit: $MAX_FD"
|
*)
|
||||||
fi
|
ulimit -n "$MAX_FD" ||
|
||||||
else
|
warn "Could not set maximum file descriptor limit to $MAX_FD"
|
||||||
warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
# For Darwin, add options to specify how the application appears in the dock
|
|
||||||
if $darwin; then
|
|
||||||
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
|
|
||||||
fi
|
|
||||||
|
|
||||||
# For Cygwin or MSYS, switch paths to Windows format before running java
|
|
||||||
if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
|
|
||||||
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
|
|
||||||
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
|
|
||||||
|
|
||||||
JAVACMD=`cygpath --unix "$JAVACMD"`
|
|
||||||
|
|
||||||
# We build the pattern for arguments to be converted via cygpath
|
|
||||||
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
|
|
||||||
SEP=""
|
|
||||||
for dir in $ROOTDIRSRAW ; do
|
|
||||||
ROOTDIRS="$ROOTDIRS$SEP$dir"
|
|
||||||
SEP="|"
|
|
||||||
done
|
|
||||||
OURCYGPATTERN="(^($ROOTDIRS))"
|
|
||||||
# Add a user-defined pattern to the cygpath arguments
|
|
||||||
if [ "$GRADLE_CYGPATTERN" != "" ] ; then
|
|
||||||
OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
|
|
||||||
fi
|
|
||||||
# Now convert the arguments - kludge to limit ourselves to /bin/sh
|
|
||||||
i=0
|
|
||||||
for arg in "$@" ; do
|
|
||||||
CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
|
|
||||||
CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
|
|
||||||
|
|
||||||
if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
|
|
||||||
eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
|
|
||||||
else
|
|
||||||
eval `echo args$i`="\"$arg\""
|
|
||||||
fi
|
|
||||||
i=`expr $i + 1`
|
|
||||||
done
|
|
||||||
case $i in
|
|
||||||
0) set -- ;;
|
|
||||||
1) set -- "$args0" ;;
|
|
||||||
2) set -- "$args0" "$args1" ;;
|
|
||||||
3) set -- "$args0" "$args1" "$args2" ;;
|
|
||||||
4) set -- "$args0" "$args1" "$args2" "$args3" ;;
|
|
||||||
5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
|
|
||||||
6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
|
|
||||||
7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
|
|
||||||
8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
|
|
||||||
9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
|
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Escape application args
|
# Collect all arguments for the java command, stacking in reverse order:
|
||||||
save () {
|
# * args from the command line
|
||||||
for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
|
# * the main class name
|
||||||
echo " "
|
# * -classpath
|
||||||
}
|
# * -D...appname settings
|
||||||
APP_ARGS=`save "$@"`
|
# * --module-path (only if needed)
|
||||||
|
# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables.
|
||||||
|
|
||||||
# Collect all arguments for the java command, following the shell quoting and substitution rules
|
# For Cygwin or MSYS, switch paths to Windows format before running java
|
||||||
eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
|
if "$cygwin" || "$msys" ; then
|
||||||
|
APP_HOME=$( cygpath --path --mixed "$APP_HOME" )
|
||||||
|
CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" )
|
||||||
|
|
||||||
|
JAVACMD=$( cygpath --unix "$JAVACMD" )
|
||||||
|
|
||||||
|
# Now convert the arguments - kludge to limit ourselves to /bin/sh
|
||||||
|
for arg do
|
||||||
|
if
|
||||||
|
case $arg in #(
|
||||||
|
-*) false ;; # don't mess with options #(
|
||||||
|
/?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath
|
||||||
|
[ -e "$t" ] ;; #(
|
||||||
|
*) false ;;
|
||||||
|
esac
|
||||||
|
then
|
||||||
|
arg=$( cygpath --path --ignore --mixed "$arg" )
|
||||||
|
fi
|
||||||
|
# Roll the args list around exactly as many times as the number of
|
||||||
|
# args, so each arg winds up back in the position where it started, but
|
||||||
|
# possibly modified.
|
||||||
|
#
|
||||||
|
# NB: a `for` loop captures its iteration list before it begins, so
|
||||||
|
# changing the positional parameters here affects neither the number of
|
||||||
|
# iterations, nor the values presented in `arg`.
|
||||||
|
shift # remove old arg
|
||||||
|
set -- "$@" "$arg" # push replacement arg
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Collect all arguments for the java command;
|
||||||
|
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
|
||||||
|
# shell script including quotes and variable substitutions, so put them in
|
||||||
|
# double quotes to make sure that they get re-expanded; and
|
||||||
|
# * put everything else in single quotes, so that it's not re-expanded.
|
||||||
|
|
||||||
|
set -- \
|
||||||
|
"-Dorg.gradle.appname=$APP_BASE_NAME" \
|
||||||
|
-classpath "$CLASSPATH" \
|
||||||
|
org.gradle.wrapper.GradleWrapperMain \
|
||||||
|
"$@"
|
||||||
|
|
||||||
|
# Use "xargs" to parse quoted args.
|
||||||
|
#
|
||||||
|
# With -n1 it outputs one arg per line, with the quotes and backslashes removed.
|
||||||
|
#
|
||||||
|
# In Bash we could simply go:
|
||||||
|
#
|
||||||
|
# readarray ARGS < <( xargs -n1 <<<"$var" ) &&
|
||||||
|
# set -- "${ARGS[@]}" "$@"
|
||||||
|
#
|
||||||
|
# but POSIX shell has neither arrays nor command substitution, so instead we
|
||||||
|
# post-process each arg (as a line of input to sed) to backslash-escape any
|
||||||
|
# character that might be a shell metacharacter, then use eval to reverse
|
||||||
|
# that process (while maintaining the separation between arguments), and wrap
|
||||||
|
# the whole thing up as a single "set" statement.
|
||||||
|
#
|
||||||
|
# This will of course break if any of these variables contains a newline or
|
||||||
|
# an unmatched quote.
|
||||||
|
#
|
||||||
|
|
||||||
|
eval "set -- $(
|
||||||
|
printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" |
|
||||||
|
xargs -n1 |
|
||||||
|
sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' |
|
||||||
|
tr '\n' ' '
|
||||||
|
)" '"$@"'
|
||||||
|
|
||||||
exec "$JAVACMD" "$@"
|
exec "$JAVACMD" "$@"
|
||||||
|
|
2
tools/crontab-scripts.txt
Normal file
2
tools/crontab-scripts.txt
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
@reboot screen -dmS web sh -c 'cd /root/hotel/; sh start_web.sh; exec bash'
|
||||||
|
@reboot screen -dmS server sh -c 'cd /root/hotel/; sh start_server.sh; exec bash'
|
9
tools/scripts/README.txt
Normal file
9
tools/scripts/README.txt
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
The run_*.sh files are for Linux operating systems.
|
||||||
|
|
||||||
|
The run_*.bat files are for Windows operating systems.
|
||||||
|
|
||||||
|
Both of them execute the project for either the web/server.
|
||||||
|
|
||||||
|
Thank you for using Havana.
|
||||||
|
|
||||||
|
-Quackster
|
8
tools/scripts/run_server.bat
Normal file
8
tools/scripts/run_server.bat
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
@echo off
|
||||||
|
title Havana Server - Habbo Hotel Emulation
|
||||||
|
|
||||||
|
set CLASSPATH=Havana-Server.jar;lib/HikariCP-3.4.1.jar;lib/mariadb-java-client-2.3.0.jar;lib/netty-all-4.1.33.Final.jar;lib/slf4j-log4j12-1.7.25.jar;lib/slf4j-api-1.7.25.jar;lib/log4j-1.2.17.jar;lib/commons-configuration2-2.2.jar;lib/commons-lang3-3.9.jar;lib/commons-lang-2.6.jar;lib/commons-validator-1.6.jar;lib/gson-2.8.0.jar;lib/spring-security-crypto-5.7.3.jar;lib/bcprov-jdk15on-1.70.jar;lib/geoip2-2.12.0.jar;lib/chesslib-1.1.1.jar;lib/commons-beanutils-1.9.2.jar;lib/httpclient-4.5.5.jar;lib/commons-logging-1.2.jar;lib/commons-digester-1.8.1.jar;lib/commons-collections-3.2.2.jar;lib/maxmind-db-1.2.2.jar;lib/jackson-databind-2.9.5.jar;lib/jackson-core-2.9.5.jar;lib/jackson-annotations-2.9.5.jar;lib/httpcore-4.4.9.jar;lib/commons-codec-1.10.jar
|
||||||
|
|
||||||
|
|
||||||
|
java -Djava.net.preferIPv4Stack=true -Djava.net.preferIPv4Addresses=true -classpath "%CLASSPATH%" org.alexdev.havana.Havana
|
||||||
|
pause
|
5
tools/scripts/run_server.sh
Normal file
5
tools/scripts/run_server.sh
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
#!/usr/bin/sh
|
||||||
|
|
||||||
|
CLASSPATH=lib/Havana-Server.jar:lib/HikariCP-3.4.1.jar:lib/mariadb-java-client-2.3.0.jar:lib/netty-all-4.1.33.Final.jar:lib/slf4j-log4j12-1.7.25.jar:lib/slf4j-api-1.7.25.jar:lib/log4j-1.2.17.jar:lib/commons-configuration2-2.2.jar:lib/commons-lang3-3.9.jar:lib/commons-lang-2.6.jar:lib/commons-validator-1.6.jar:lib/gson-2.8.0.jar:lib/spring-security-crypto-5.7.3.jar:lib/bcprov-jdk15on-1.70.jar:lib/geoip2-2.12.0.jar:lib/chesslib-1.1.1.jar:lib/commons-beanutils-1.9.2.jar:lib/httpclient-4.5.5.jar:lib/commons-logging-1.2.jar:lib/commons-digester-1.8.1.jar:lib/commons-collections-3.2.2.jar:lib/maxmind-db-1.2.2.jar:lib/jackson-databind-2.9.5.jar:lib/jackson-core-2.9.5.jar:lib/jackson-annotations-2.9.5.jar:lib/httpcore-4.4.9.jar:lib/commons-codec-1.10.jar
|
||||||
|
|
||||||
|
java -classpath $CLASSPATH org.alexdev.havana.Havana
|
8
tools/scripts/run_web.bat
Normal file
8
tools/scripts/run_web.bat
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
@echo off
|
||||||
|
title Havana Server - Habbo Hotel Emulation
|
||||||
|
|
||||||
|
set CLASSPATH=Havana-Web.jar;lib/ini4j-0.5.4.jar;lib/pebble-3.1.5.jar;lib/Havana-Server.jar;lib/HikariCP-3.4.1.jar;lib/mariadb-java-client-2.3.0.jar;lib/commons-configuration2-2.2.jar;lib/commons-text-1.5.jar;lib/htmlcompressor-maven-plugin-1.3.jar;lib/commons-io-2.5.jar;lib/velocity-tools-2.0.jar;lib/struts-taglib-1.3.8.jar;lib/struts-tiles-1.3.8.jar;lib/struts-core-1.3.8.jar;lib/commons-validator-1.6.jar;lib/geoip2-2.12.0.jar;lib/httpclient-4.5.5.jar;lib/duckHTTPD-all.jar;lib/jsoup-1.13.1.jar;lib/slf4j-log4j12-1.7.25.jar;lib/gson-2.8.0.jar;lib/mail-1.4.7.jar;lib/lazysodium-java-5.0.1.jar;lib/resource-loader-2.0.1.jar;lib/jna-5.8.0.jar;lib/unbescape-1.1.6.RELEASE.jar;lib/slf4j-api-1.7.30.jar;lib/commons-lang3-3.9.jar;lib/commons-chain-1.1.jar;lib/commons-digester-1.8.1.jar;lib/commons-beanutils-1.9.2.jar;lib/commons-logging-1.2.jar;lib/velocity-1.6.2.jar;lib/commons-collections-3.2.2.jar;lib/httpcore-4.4.9.jar;lib/commons-codec-1.10.jar;lib/netty-all-4.1.33.Final.jar;lib/log4j-1.2.17.jar;lib/commons-lang-2.6.jar;lib/spring-security-crypto-5.7.3.jar;lib/bcprov-jdk15on-1.70.jar;lib/chesslib-1.1.1.jar;lib/htmlcompressor-1.5.2.jar;lib/yuicompressor-2.4.6.jar;lib/jsp-api-2.1.jar;lib/json-20090211.jar;lib/maven-plugin-api-3.0.3.jar;lib/activation-1.1.jar;lib/maxmind-db-1.2.2.jar;lib/jackson-databind-2.9.5.jar;lib/jackson-core-2.9.5.jar;lib/jackson-annotations-2.9.5.jar;lib/js-1.6R7.jar;lib/dom4j-1.1.jar;lib/oro-2.0.8.jar;lib/sslext-1.2-0.jar;lib/maven-model-3.0.3.jar;lib/maven-artifact-3.0.3.jar;lib/sisu-inject-plexus-2.1.1.jar;lib/antlr-2.7.2.jar;lib/plexus-utils-2.0.6.jar;lib/plexus-component-annotations-1.5.5.jar;lib/plexus-classworlds-2.4.jar;lib/sisu-inject-bean-2.1.1.jar;lib/sisu-guice-2.9.4-no_aop.jar
|
||||||
|
|
||||||
|
|
||||||
|
java -Djava.net.preferIPv4Stack=true -Djava.net.preferIPv4Addresses=true -classpath "%CLASSPATH%" org.alexdev.http.HavanaWeb
|
||||||
|
pause
|
5
tools/scripts/run_web.sh
Normal file
5
tools/scripts/run_web.sh
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
#!/usr/bin/sh
|
||||||
|
|
||||||
|
CLASSPATH=Havana-Web.jar:lib/ini4j-0.5.4.jar:lib/pebble-3.1.5.jar:lib/Havana-Server.jar:lib/HikariCP-3.4.1.jar:lib/mariadb-java-client-2.3.0.jar:lib/commons-configuration2-2.2.jar:lib/commons-text-1.5.jar:lib/htmlcompressor-maven-plugin-1.3.jar:lib/commons-io-2.5.jar:lib/velocity-tools-2.0.jar:lib/struts-taglib-1.3.8.jar:lib/struts-tiles-1.3.8.jar:lib/struts-core-1.3.8.jar:lib/commons-validator-1.6.jar:lib/geoip2-2.12.0.jar:lib/httpclient-4.5.5.jar:lib/duckHTTPD-all.jar:lib/jsoup-1.13.1.jar:lib/slf4j-log4j12-1.7.25.jar:lib/gson-2.8.0.jar:lib/mail-1.4.7.jar:lib/lazysodium-java-5.0.1.jar:lib/resource-loader-2.0.1.jar:lib/jna-5.8.0.jar:lib/unbescape-1.1.6.RELEASE.jar:lib/slf4j-api-1.7.30.jar:lib/commons-lang3-3.9.jar:lib/commons-chain-1.1.jar:lib/commons-digester-1.8.1.jar:lib/commons-beanutils-1.9.2.jar:lib/commons-logging-1.2.jar:lib/velocity-1.6.2.jar:lib/commons-collections-3.2.2.jar:lib/httpcore-4.4.9.jar:lib/commons-codec-1.10.jar:lib/netty-all-4.1.33.Final.jar:lib/log4j-1.2.17.jar:lib/commons-lang-2.6.jar:lib/spring-security-crypto-5.7.3.jar:lib/bcprov-jdk15on-1.70.jar:lib/chesslib-1.1.1.jar:lib/htmlcompressor-1.5.2.jar:lib/yuicompressor-2.4.6.jar:lib/jsp-api-2.1.jar:lib/json-20090211.jar:lib/maven-plugin-api-3.0.3.jar:lib/activation-1.1.jar:lib/maxmind-db-1.2.2.jar:lib/jackson-databind-2.9.5.jar:lib/jackson-core-2.9.5.jar:lib/jackson-annotations-2.9.5.jar:lib/js-1.6R7.jar:lib/dom4j-1.1.jar:lib/oro-2.0.8.jar:lib/sslext-1.2-0.jar:lib/maven-model-3.0.3.jar:lib/maven-artifact-3.0.3.jar:lib/sisu-inject-plexus-2.1.1.jar:lib/antlr-2.7.2.jar:lib/plexus-utils-2.0.6.jar:lib/plexus-component-annotations-1.5.5.jar:lib/plexus-classworlds-2.4.jar:lib/sisu-inject-bean-2.1.1.jar:lib/sisu-guice-2.9.4-no_aop.jar
|
||||||
|
|
||||||
|
java -Djava.net.preferIPv4Stack=true -Djava.net.preferIPv4Addresses=true -classpath $CLASSPATH org.alexdev.havana.Havana
|
Loading…
Add table
Reference in a new issue