Compare commits
5 Commits
aed10ab0bd
...
release-v1
| Author | SHA1 | Date | |
|---|---|---|---|
| cb1e5f43ff | |||
|
|
02589a3ce9 | ||
|
|
0a6645b526 | ||
|
|
13616a2f1e | ||
|
|
69726cba75 |
@@ -13,5 +13,5 @@ services:
|
||||
- NET_ADMIN
|
||||
- SYS_MODULE
|
||||
environment:
|
||||
# - PASSWORD=p
|
||||
# - PASSWORD_HASH=p
|
||||
- WG_HOST=192.168.1.233
|
||||
|
||||
@@ -6,13 +6,14 @@ services:
|
||||
environment:
|
||||
# Change Language:
|
||||
# (Supports: en, ua, ru, tr, no, pl, fr, de, ca, es, ko, vi, nl, is, pt, chs, cht, it, th, hi)
|
||||
- LANG=de
|
||||
# - LANG=de
|
||||
# ⚠️ Required:
|
||||
# Change this to your host's public address
|
||||
- WG_HOST=raspberrypi.local
|
||||
- WG_HOST=192.168.11.3
|
||||
|
||||
# Optional:
|
||||
# - PASSWORD_HASH=$$2y$$10$$hBCoykrB95WSzuV4fafBzOHWKu9sbyVa34GJr8VV5R/pIelfEMYyG (needs double $$, hash of 'foobar123'; see "How_to_generate_an_bcrypt_hash.md" for generate the hash)
|
||||
- PASSWORD_HASH=$$2a$$12$$ZwvA8aZH/3JCrRr448G2rOy0Tb8xHHfV4wjN6Q33eWVACKdfMAgRq
|
||||
# (needs double $$, see "How_to_generate_an_bcrypt_hash.md" for generate the hash)
|
||||
# - PORT=51821
|
||||
# - WG_PORT=51820
|
||||
# - WG_CONFIG_PORT=92820
|
||||
@@ -28,8 +29,8 @@ services:
|
||||
# - UI_TRAFFIC_STATS=true
|
||||
# - UI_CHART_TYPE=0 # (0 Charts disabled, 1 # Line chart, 2 # Area chart, 3 # Bar chart)
|
||||
|
||||
image: ghcr.io/wg-easy/wg-easy
|
||||
container_name: wg-easy
|
||||
image: ghcr.io/wg-easy/wg-easy:14
|
||||
container_name: wireguard
|
||||
volumes:
|
||||
- etc_wireguard:/etc/wireguard
|
||||
ports:
|
||||
|
||||
@@ -5,6 +5,8 @@ const { release: { version } } = require('./package.json');
|
||||
module.exports.RELEASE = version;
|
||||
module.exports.PORT = process.env.PORT || '51821';
|
||||
module.exports.WEBUI_HOST = process.env.WEBUI_HOST || '0.0.0.0';
|
||||
/** This is only kept for migration purpose. DO NOT USE! */
|
||||
module.exports.PASSWORD = process.env.PASSWORD;
|
||||
module.exports.PASSWORD_HASH = process.env.PASSWORD_HASH;
|
||||
module.exports.WG_PATH = process.env.WG_PATH || '/etc/wireguard/';
|
||||
module.exports.WG_DEVICE = process.env.WG_DEVICE || 'eth0';
|
||||
|
||||
@@ -28,6 +28,7 @@ const {
|
||||
PORT,
|
||||
WEBUI_HOST,
|
||||
RELEASE,
|
||||
PASSWORD,
|
||||
PASSWORD_HASH,
|
||||
LANG,
|
||||
UI_TRAFFIC_STATS,
|
||||
@@ -306,6 +307,10 @@ module.exports = class Server {
|
||||
}),
|
||||
);
|
||||
|
||||
if (PASSWORD) {
|
||||
throw new Error('DO NOT USE PASSWORD ENVIRONMENT VARIABLE. USE PASSWORD_HASH INSTEAD.\nSee https://github.com/wg-easy/wg-easy/blob/master/How_to_generate_an_bcrypt_hash.md');
|
||||
}
|
||||
|
||||
createServer(toNodeListener(app)).listen(PORT, WEBUI_HOST);
|
||||
debug(`Listening on http://${WEBUI_HOST}:${PORT}`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user