Skip to content

v2.12.2 #4261

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

Merged
merged 69 commits into from
Dec 29, 2024
Merged

v2.12.2 #4261

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
69 commits
Select commit Hold shift + click to select a range
d499e2b
Push PR and github branch builds to separate docker image
jc21 Oct 17, 2024
96c58b2
normalize indentations in certbot-dns-plugins.json
Guiorgy Oct 17, 2024
d92421d
doc(site) - default credentials change
ttodua Oct 18, 2024
68a9baf
minor
ttodua Oct 18, 2024
0cf6b9c
Merge pull request #4084 from ttodua/patch-1
jc21 Oct 22, 2024
ee41bb5
Merge pull request #4078 from Guiorgy/patch-1
jc21 Oct 22, 2024
d7e0558
http2 directive
dreik Oct 23, 2024
dad8d0c
Update _access.conf
chrismaffey Oct 24, 2024
d17c85e
Merge pull request #4107 from chrismaffey/patch-1
jc21 Oct 24, 2024
2e9a4f1
Update put.json
chrismaffey Oct 24, 2024
ffe05eb
Merge pull request #4108 from chrismaffey/patch-2
jc21 Oct 24, 2024
eaf6335
Merge pull request #4106 from dreik/develop
jc21 Oct 24, 2024
1c1cee3
feat: Add leaseweb to certbot-dns-plugins
prospo Oct 25, 2024
e9d4f5b
Remove variable usage from proxy_pass directive to fix resolution issues
mitossoft-rd Oct 27, 2024
a55de38
Fix URL format
mitossoft-rd Oct 28, 2024
f7d3ca0
Cleaning unused variable.
mitossoft-rd Oct 28, 2024
17246e4
Merge pull request #4118 from mitossoft-rd/patch-1
jc21 Oct 30, 2024
25a26d6
Merge pull request #4112 from prospo/develop
jc21 Oct 30, 2024
62c94f3
Bump elliptic from 6.5.7 to 6.6.0 in /frontend
dependabot[bot] Oct 31, 2024
d6791f4
docs(setup): Remove deprecated version from docker-compose.yml
jonasrdl Oct 31, 2024
a0b26b9
Add woff2 format to assets.conf for Cache Assets
irexyc Nov 4, 2024
c171752
Added certbot plugin for Beget DNS service
Medan-rfz Nov 7, 2024
595a742
Change beget plugin
Medan-rfz Nov 10, 2024
10b9a49
Update version 'certbot-beget-plugin'
Medan-rfz Nov 10, 2024
4c89379
Update version 'certbot-beget-plugin'
Medan-rfz Nov 10, 2024
a56342c
Fix credentials
Medan-rfz Nov 10, 2024
87998a0
Fix bootloop if stream is used for http/https port
Jasparigus Nov 14, 2024
20646e7
Bump @eslint/plugin-kit from 0.2.0 to 0.2.3 in /test
dependabot[bot] Nov 15, 2024
126d3d4
Bump certbot-dns-porkbun
andrew-codechimp Nov 17, 2024
640a1ee
Return generic auth error to prevent user enumeration attacks
tametsi Nov 22, 2024
07a4e57
Merge pull request #4179 from tametsi/develop
jc21 Nov 23, 2024
2075f98
Bump cross-spawn from 7.0.3 to 7.0.6 in /backend
dependabot[bot] Nov 24, 2024
151160a
Update index.md: add link to Proxmox VE Helper-Scripts
muescha Nov 24, 2024
93ea17a
Fix entries of a deleted user break the UI
kerstenremco Nov 25, 2024
586afc0
Merge pull request #4187 from kerstenremco/avatar
jc21 Nov 25, 2024
b20dc5e
Merge pull request #4167 from NginxProxyManager/dependabot/npm_and_ya…
jc21 Nov 25, 2024
cb3e4ed
Merge pull request #4137 from irexyc/add-woff2-asset
jc21 Nov 25, 2024
53ed12b
Merge pull request #4163 from Jasparigus/stream_error_correction
jc21 Nov 25, 2024
4ea50ca
Merge pull request #4126 from jonasrdl/remove-deprecated-version-line
jc21 Nov 25, 2024
81c9038
Refactor user form structure
badkeyy Nov 27, 2024
61e2bde
Merge pull request #4184 from NginxProxyManager/dependabot/npm_and_ya…
jc21 Dec 1, 2024
fe068a8
Bump cross-spawn from 7.0.3 to 7.0.6 in /test
dependabot[bot] Dec 1, 2024
97212f2
Merge pull request #4123 from NginxProxyManager/dependabot/npm_and_ya…
jc21 Dec 2, 2024
8351dd4
Merge pull request #4199 from NginxProxyManager/dependabot/npm_and_ya…
jc21 Dec 2, 2024
03018d2
Merge branch 'NginxProxyManager:develop' into bugfix/fix-user-edit-em…
badkeyy Dec 4, 2024
19ed4c1
Change click to submit
badkeyy Dec 4, 2024
d26e8c1
Change onRender function to always update the dashboard stats
badkeyy Dec 4, 2024
fcf4117
Merge pull request #4206 from badkeyy/bugfix/update-dashboard-stats-o…
jc21 Dec 4, 2024
b3de76c
Merge pull request #4192 from badkeyy/bugfix/fix-user-edit-email-form…
jc21 Dec 4, 2024
d6b98f5
Merge branch 'NginxProxyManager:develop' into develop
Medan-rfz Dec 7, 2024
c6630e8
Update version 'certbot-beget-plugin' & fix credentials content
Medan-rfz Dec 7, 2024
56033be
Add hostingnl
TECH7Fox Dec 8, 2024
c6eca25
Bump nanoid from 3.3.7 to 3.3.8 in /docs
dependabot[bot] Dec 14, 2024
ae2ac8a
Merge pull request #4230 from NginxProxyManager/dependabot/npm_and_ya…
jc21 Dec 16, 2024
2a4093c
Merge pull request #4215 from TECH7Fox/patch-1
jc21 Dec 16, 2024
805968a
Merge pull request #4185 from muescha/patch-1
jc21 Dec 16, 2024
f537619
Revert "Change onRender function to always update the dashboard stats"
Dec 19, 2024
7f9240d
Add custom configuration to dead_host.conf
miguelangel-nubla Dec 19, 2024
3eecf7a
Add custom configuration to 404 hosts
miguelangel-nubla Dec 20, 2024
be5278f
Merge pull request #4247 from miguelangel-nubla/patch-1
jc21 Dec 23, 2024
f90d839
Merge pull request #4246 from JanzenJohn/develop
jc21 Dec 23, 2024
ca3ee98
Postgres Support
jc21 Dec 23, 2024
1406e75
Merge pull request #4254 from NginxProxyManager/postgres
jc21 Dec 24, 2024
e2011ee
Bump version
jc21 Dec 24, 2024
fc30a92
Open port for authentik in dev
jc21 Dec 24, 2024
98e5997
upgrade certbot-dns-aliyun plugin from 0.38.1 to 2.0.0
bigcat26 Dec 26, 2024
6415f28
Merge pull request #4256 from bigcat26/develop
jc21 Dec 29, 2024
e50e3de
Merge pull request #4169 from andrew-codechimp/bump-porkbun
jc21 Dec 29, 2024
ec12d8f
Merge pull request #4148 from Medan-rfz/develop
jc21 Dec 29, 2024
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
2 changes: 1 addition & 1 deletion .version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.12.1
2.12.2
48 changes: 46 additions & 2 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ pipeline {
steps {
script {
// Defaults to the Branch name, which is applies to all branches AND pr's
buildxPushTags = "-t docker.io/jc21/${IMAGE}:github-${BRANCH_LOWER}"
buildxPushTags = "-t docker.io/nginxproxymanager/${IMAGE}-dev:${BRANCH_LOWER}"
}
}
}
Expand Down Expand Up @@ -167,6 +167,44 @@ pipeline {
}
}
}
stage('Test Postgres') {
environment {
COMPOSE_PROJECT_NAME = "npm_${BRANCH_LOWER}_${BUILD_NUMBER}_postgres"
COMPOSE_FILE = 'docker/docker-compose.ci.yml:docker/docker-compose.ci.postgres.yml'
}
when {
not {
equals expected: 'UNSTABLE', actual: currentBuild.result
}
}
steps {
sh 'rm -rf ./test/results/junit/*'
sh './scripts/ci/fulltest-cypress'
}
post {
always {
// Dumps to analyze later
sh 'mkdir -p debug/postgres'
sh 'docker logs $(docker-compose ps --all -q fullstack) > debug/postgres/docker_fullstack.log 2>&1'
sh 'docker logs $(docker-compose ps --all -q stepca) > debug/postgres/docker_stepca.log 2>&1'
sh 'docker logs $(docker-compose ps --all -q pdns) > debug/postgres/docker_pdns.log 2>&1'
sh 'docker logs $(docker-compose ps --all -q pdns-db) > debug/postgres/docker_pdns-db.log 2>&1'
sh 'docker logs $(docker-compose ps --all -q dnsrouter) > debug/postgres/docker_dnsrouter.log 2>&1'
sh 'docker logs $(docker-compose ps --all -q db-postgres) > debug/postgres/docker_db-postgres.log 2>&1'
sh 'docker logs $(docker-compose ps --all -q authentik) > debug/postgres/docker_authentik.log 2>&1'
sh 'docker logs $(docker-compose ps --all -q authentik-redis) > debug/postgres/docker_authentik-redis.log 2>&1'
sh 'docker logs $(docker-compose ps --all -q authentik-ldap) > debug/postgres/docker_authentik-ldap.log 2>&1'

junit 'test/results/junit/*'
sh 'docker-compose down --remove-orphans --volumes -t 30 || true'
}
unstable {
dir(path: 'testing/results') {
archiveArtifacts(allowEmptyArchive: true, artifacts: '**/*', excludes: '**/*.xml')
}
}
}
}
stage('MultiArch Build') {
when {
not {
Expand Down Expand Up @@ -203,7 +241,13 @@ pipeline {
}
steps {
script {
npmGithubPrComment("Docker Image for build ${BUILD_NUMBER} is available on [DockerHub](https://cloud.docker.com/repository/docker/jc21/${IMAGE}) as `jc21/${IMAGE}:github-${BRANCH_LOWER}`\n\n**Note:** ensure you backup your NPM instance before testing this PR image! Especially if this PR contains database changes.", true)
npmGithubPrComment("""Docker Image for build ${BUILD_NUMBER} is available on
[DockerHub](https://cloud.docker.com/repository/docker/nginxproxymanager/${IMAGE}-dev)
as `nginxproxymanager/${IMAGE}-dev:${BRANCH_LOWER}`

**Note:** ensure you backup your NPM instance before testing this image! Especially if there are database changes
**Note:** this is a different docker image namespace than the official image
""", true)
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<p align="center">
<img src="https://nginxproxymanager.com/github.png">
<br><br>
<img src="https://img.shields.io/badge/version-2.12.1-green.svg?style=for-the-badge">
<img src="https://img.shields.io/badge/version-2.12.2-green.svg?style=for-the-badge">
<a href="https://hub.docker.com/repository/docker/jc21/nginx-proxy-manager">
<img src="https://img.shields.io/docker/stars/jc21/nginx-proxy-manager.svg?style=for-the-badge">
</a>
Expand Down
14 changes: 10 additions & 4 deletions backend/internal/access-list.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ const internalAccessList = {

return internalAccessList.build(row)
.then(() => {
if (row.proxy_host_count) {
if (parseInt(row.proxy_host_count, 10)) {
return internalNginx.bulkGenerateConfigs('proxy_host', row.proxy_hosts);
}
})
Expand Down Expand Up @@ -223,7 +223,7 @@ const internalAccessList = {
.then((row) => {
return internalAccessList.build(row)
.then(() => {
if (row.proxy_host_count) {
if (parseInt(row.proxy_host_count, 10)) {
return internalNginx.bulkGenerateConfigs('proxy_host', row.proxy_hosts);
}
}).then(internalNginx.reload)
Expand Down Expand Up @@ -252,7 +252,10 @@ const internalAccessList = {
let query = accessListModel
.query()
.select('access_list.*', accessListModel.raw('COUNT(proxy_host.id) as proxy_host_count'))
.joinRaw('LEFT JOIN `proxy_host` ON `proxy_host`.`access_list_id` = `access_list`.`id` AND `proxy_host`.`is_deleted` = 0')
.leftJoin('proxy_host', function() {
this.on('proxy_host.access_list_id', '=', 'access_list.id')
.andOn('proxy_host.is_deleted', '=', 0);
})
.where('access_list.is_deleted', 0)
.andWhere('access_list.id', data.id)
.allowGraph('[owner,items,clients,proxy_hosts.[certificate,access_list.[clients,items]]]')
Expand Down Expand Up @@ -373,7 +376,10 @@ const internalAccessList = {
let query = accessListModel
.query()
.select('access_list.*', accessListModel.raw('COUNT(proxy_host.id) as proxy_host_count'))
.joinRaw('LEFT JOIN `proxy_host` ON `proxy_host`.`access_list_id` = `access_list`.`id` AND `proxy_host`.`is_deleted` = 0')
.leftJoin('proxy_host', function() {
this.on('proxy_host.access_list_id', '=', 'access_list.id')
.andOn('proxy_host.is_deleted', '=', 0);
})
.where('access_list.is_deleted', 0)
.groupBy('access_list.id')
.allowGraph('[owner,items,clients]')
Expand Down
9 changes: 5 additions & 4 deletions backend/internal/audit-log.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
const error = require('../lib/error');
const auditLogModel = require('../models/audit-log');
const error = require('../lib/error');
const auditLogModel = require('../models/audit-log');
const {castJsonIfNeed} = require('../lib/helpers');

const internalAuditLog = {

Expand All @@ -22,9 +23,9 @@ const internalAuditLog = {
.allowGraph('[user]');

// Query is used for searching
if (typeof search_query === 'string') {
if (typeof search_query === 'string' && search_query.length > 0) {
query.where(function () {
this.where('meta', 'like', '%' + search_query + '%');
this.where(castJsonIfNeed('meta'), 'like', '%' + search_query + '%');
});
}

Expand Down
7 changes: 4 additions & 3 deletions backend/internal/dead-host.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ const internalHost = require('./host');
const internalNginx = require('./nginx');
const internalAuditLog = require('./audit-log');
const internalCertificate = require('./certificate');
const {castJsonIfNeed} = require('../lib/helpers');

function omissions () {
return ['is_deleted'];
Expand Down Expand Up @@ -409,16 +410,16 @@ const internalDeadHost = {
.where('is_deleted', 0)
.groupBy('id')
.allowGraph('[owner,certificate]')
.orderBy('domain_names', 'ASC');
.orderBy(castJsonIfNeed('domain_names'), 'ASC');

if (access_data.permission_visibility !== 'all') {
query.andWhere('owner_user_id', access.token.getUserId(1));
}

// Query is used for searching
if (typeof search_query === 'string') {
if (typeof search_query === 'string' && search_query.length > 0) {
query.where(function () {
this.where('domain_names', 'like', '%' + search_query + '%');
this.where(castJsonIfNeed('domain_names'), 'like', '%' + search_query + '%');
});
}

Expand Down
13 changes: 7 additions & 6 deletions backend/internal/host.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ const _ = require('lodash');
const proxyHostModel = require('../models/proxy_host');
const redirectionHostModel = require('../models/redirection_host');
const deadHostModel = require('../models/dead_host');
const {castJsonIfNeed} = require('../lib/helpers');

const internalHost = {

Expand All @@ -17,7 +18,7 @@ const internalHost = {
cleanSslHstsData: function (data, existing_data) {
existing_data = existing_data === undefined ? {} : existing_data;

let combined_data = _.assign({}, existing_data, data);
const combined_data = _.assign({}, existing_data, data);

if (!combined_data.certificate_id) {
combined_data.ssl_forced = false;
Expand Down Expand Up @@ -73,7 +74,7 @@ const internalHost = {
* @returns {Promise}
*/
getHostsWithDomains: function (domain_names) {
let promises = [
const promises = [
proxyHostModel
.query()
.where('is_deleted', 0),
Expand Down Expand Up @@ -125,19 +126,19 @@ const internalHost = {
* @returns {Promise}
*/
isHostnameTaken: function (hostname, ignore_type, ignore_id) {
let promises = [
const promises = [
proxyHostModel
.query()
.where('is_deleted', 0)
.andWhere('domain_names', 'like', '%' + hostname + '%'),
.andWhere(castJsonIfNeed('domain_names'), 'like', '%' + hostname + '%'),
redirectionHostModel
.query()
.where('is_deleted', 0)
.andWhere('domain_names', 'like', '%' + hostname + '%'),
.andWhere(castJsonIfNeed('domain_names'), 'like', '%' + hostname + '%'),
deadHostModel
.query()
.where('is_deleted', 0)
.andWhere('domain_names', 'like', '%' + hostname + '%')
.andWhere(castJsonIfNeed('domain_names'), 'like', '%' + hostname + '%')
];

return Promise.all(promises)
Expand Down
7 changes: 4 additions & 3 deletions backend/internal/proxy-host.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ const internalHost = require('./host');
const internalNginx = require('./nginx');
const internalAuditLog = require('./audit-log');
const internalCertificate = require('./certificate');
const {castJsonIfNeed} = require('../lib/helpers');

function omissions () {
return ['is_deleted', 'owner.is_deleted'];
Expand Down Expand Up @@ -416,16 +417,16 @@ const internalProxyHost = {
.where('is_deleted', 0)
.groupBy('id')
.allowGraph('[owner,access_list,certificate]')
.orderBy('domain_names', 'ASC');
.orderBy(castJsonIfNeed('domain_names'), 'ASC');

if (access_data.permission_visibility !== 'all') {
query.andWhere('owner_user_id', access.token.getUserId(1));
}

// Query is used for searching
if (typeof search_query === 'string') {
if (typeof search_query === 'string' && search_query.length > 0) {
query.where(function () {
this.where('domain_names', 'like', '%' + search_query + '%');
this.where(castJsonIfNeed('domain_names'), 'like', `%${search_query}%`);
});
}

Expand Down
7 changes: 4 additions & 3 deletions backend/internal/redirection-host.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ const internalHost = require('./host');
const internalNginx = require('./nginx');
const internalAuditLog = require('./audit-log');
const internalCertificate = require('./certificate');
const {castJsonIfNeed} = require('../lib/helpers');

function omissions () {
return ['is_deleted'];
Expand Down Expand Up @@ -409,16 +410,16 @@ const internalRedirectionHost = {
.where('is_deleted', 0)
.groupBy('id')
.allowGraph('[owner,certificate]')
.orderBy('domain_names', 'ASC');
.orderBy(castJsonIfNeed('domain_names'), 'ASC');

if (access_data.permission_visibility !== 'all') {
query.andWhere('owner_user_id', access.token.getUserId(1));
}

// Query is used for searching
if (typeof search_query === 'string') {
if (typeof search_query === 'string' && search_query.length > 0) {
query.where(function () {
this.where('domain_names', 'like', '%' + search_query + '%');
this.where(castJsonIfNeed('domain_names'), 'like', `%${search_query}%`);
});
}

Expand Down
13 changes: 7 additions & 6 deletions backend/internal/stream.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ const utils = require('../lib/utils');
const streamModel = require('../models/stream');
const internalNginx = require('./nginx');
const internalAuditLog = require('./audit-log');
const {castJsonIfNeed} = require('../lib/helpers');

function omissions () {
return ['is_deleted'];
Expand Down Expand Up @@ -293,21 +294,21 @@ const internalStream = {
getAll: (access, expand, search_query) => {
return access.can('streams:list')
.then((access_data) => {
let query = streamModel
const query = streamModel
.query()
.where('is_deleted', 0)
.groupBy('id')
.allowGraph('[owner]')
.orderBy('incoming_port', 'ASC');
.orderByRaw('CAST(incoming_port AS INTEGER) ASC');

if (access_data.permission_visibility !== 'all') {
query.andWhere('owner_user_id', access.token.getUserId(1));
}

// Query is used for searching
if (typeof search_query === 'string') {
if (typeof search_query === 'string' && search_query.length > 0) {
query.where(function () {
this.where('incoming_port', 'like', '%' + search_query + '%');
this.where(castJsonIfNeed('incoming_port'), 'like', `%${search_query}%`);
});
}

Expand All @@ -327,9 +328,9 @@ const internalStream = {
* @returns {Promise}
*/
getCount: (user_id, visibility) => {
let query = streamModel
const query = streamModel
.query()
.count('id as count')
.count('id AS count')
.where('is_deleted', 0);

if (visibility !== 'all') {
Expand Down
8 changes: 5 additions & 3 deletions backend/internal/token.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ const authModel = require('../models/auth');
const helpers = require('../lib/helpers');
const TokenModel = require('../models/token');

const ERROR_MESSAGE_INVALID_AUTH = 'Invalid email or password';

module.exports = {

/**
Expand Down Expand Up @@ -69,15 +71,15 @@ module.exports = {
};
});
} else {
throw new error.AuthError('Invalid password');
throw new error.AuthError(ERROR_MESSAGE_INVALID_AUTH);
}
});
} else {
throw new error.AuthError('No password auth for user');
throw new error.AuthError(ERROR_MESSAGE_INVALID_AUTH);
}
});
} else {
throw new error.AuthError('No relevant user found');
throw new error.AuthError(ERROR_MESSAGE_INVALID_AUTH);
}
});
},
Expand Down
Loading
Loading