Compare commits

...

27 commits

Author SHA1 Message Date
Roman d54b389ded
Merge 702b7ae162 into 1e5cab7929 2025-02-06 09:46:31 +02:00
sturman 702b7ae162 Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties 2025-02-06 09:45:33 +02:00
LinuxServer-CI 1e5cab7929
Bot Updating Package Versions 2025-02-04 15:58:27 +00:00
LinuxServer-CI 5d21a87536
Bot Updating Templated Files 2025-02-04 15:53:50 +00:00
LinuxServer-CI 650bb3fe0b
Bot Updating Templated Files 2025-02-04 15:52:39 +00:00
quietsy 557d13ba85
Merge pull request #130 from linuxserver/add-project-categories
Add categories to readme-vars.yml
2025-01-23 09:39:45 +02:00
quietsy 3b80942c03 Add categories to readme-vars.yml 2025-01-22 22:52:23 +02:00
sturman 04db7da930 Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties 2025-01-06 23:10:37 +02:00
sturman 65fc4de5d4 Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties
# Conflicts:
#	readme-vars.yml
2024-12-23 12:10:17 +02:00
sturman 0aa4543e91 Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties 2024-11-10 12:21:29 +02:00
sturman 3c43dd6cd8 Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties 2024-10-10 12:33:26 +03:00
Roman 7654109ffa
Merge branch 'linuxserver:main' into replace-placeholers-in-proeprties 2024-09-27 09:42:48 +03:00
sturman a60a8bd34f Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties 2024-08-27 09:24:48 +03:00
sturman 61c4b501a0 Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties
# Conflicts:
#	README.md
#	readme-vars.yml
2024-08-17 10:39:00 +03:00
sturman 76bcaf322d Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties 2024-07-17 22:15:18 +03:00
sturman 4ea124f871 Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties 2024-06-04 15:27:21 +03:00
sturman 96d3003d43 Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties
# Conflicts:
#	readme-vars.yml
2024-05-21 16:10:51 +03:00
sturman 9f8030f07a Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties 2024-04-29 15:19:50 +03:00
sturman 1a538030be Add new environment variables to README.md 2024-03-20 12:27:16 +02:00
sturman 41b367182a Merge remote-tracking branch 'origin/main' into replace-placeholers-in-proeprties 2024-03-20 12:20:41 +02:00
sturman 27594b95a8 Sort dependencies 2024-02-24 21:51:16 +02:00
sturman 36abd4e762 Revert "Install envsubst alternative (Go version)"
This reverts commit 62dab7b4
2024-02-24 21:50:33 +02:00
sturman 3be04fb262 Fix log message 2024-02-24 20:55:31 +02:00
sturman a1b59c28ec Set DEBIAN_FRONTEND environment variable 2024-02-24 20:38:41 +02:00
sturman 62dab7b4c2 Install envsubst alternative (Go version) 2024-02-24 20:35:15 +02:00
sturman 1146ec48fd Install envsubst 2024-02-24 20:20:02 +02:00
sturman fb1bd160e3 Use envsubst to replace placeholders in system.properties 2024-02-24 20:19:53 +02:00
11 changed files with 72 additions and 70 deletions

View file

@ -6,7 +6,7 @@
* Read, and fill the Pull Request template
* If this is a fix for a typo (in code, documentation, or the README) please file an issue and let us sort it out. We do not need a PR
* If the PR is addressing an existing issue include, closes #\<issue number>, in the body of the PR commit message
* If you want to discuss changes, you can also bring it up in [#dev-talk](https://discordapp.com/channels/354974912613449730/757585807061155840) in our [Discord server](https://discord.gg/YWrKVTn)
* If you want to discuss changes, you can also bring it up in [#dev-talk](https://discordapp.com/channels/354974912613449730/757585807061155840) in our [Discord server](https://linuxserver.io/discord)
## Common files

View file

@ -1,7 +1,7 @@
blank_issues_enabled: false
contact_links:
- name: Discord chat support
url: https://discord.gg/YWrKVTn
url: https://linuxserver.io/discord
about: Realtime support / chat with the community and the team.
- name: Discourse discussion forum

View file

@ -15,7 +15,10 @@ jobs:
SKIP_EXTERNAL_TRIGGER: ${{ vars.SKIP_EXTERNAL_TRIGGER }}
run: |
printf "# External trigger for docker-unifi-network-application\n\n" >> $GITHUB_STEP_SUMMARY
if grep -q "^unifi-network-application_main" <<< "${SKIP_EXTERNAL_TRIGGER}"; then
if grep -q "^unifi-network-application_main_" <<< "${SKIP_EXTERNAL_TRIGGER}"; then
echo "> [!NOTE]" >> $GITHUB_STEP_SUMMARY
echo "> Github organizational variable \`SKIP_EXTERNAL_TRIGGER\` contains \`unifi-network-application_main_\`; will skip trigger if version matches." >> $GITHUB_STEP_SUMMARY
elif grep -q "^unifi-network-application_main" <<< "${SKIP_EXTERNAL_TRIGGER}"; then
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
echo "> Github organizational variable \`SKIP_EXTERNAL_TRIGGER\` contains \`unifi-network-application_main\`; skipping trigger." >> $GITHUB_STEP_SUMMARY
exit 0
@ -25,6 +28,11 @@ jobs:
printf "\n## Retrieving external version\n\n" >> $GITHUB_STEP_SUMMARY
EXT_RELEASE=$(curl -sX GET https://dl.ui.com/unifi/debian/dists/stable/ubiquiti/binary-amd64/Packages.gz | gunzip | grep -A 7 -m 1 'Package: unifi' | awk -F ': ' '/Version/{print $2;exit}' | awk -F '-' '{print $1}')
echo "Type is \`custom_version_command\`" >> $GITHUB_STEP_SUMMARY
if grep -q "^unifi-network-application_main_${EXT_RELEASE}" <<< "${SKIP_EXTERNAL_TRIGGER}"; then
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
echo "> Github organizational variable \`SKIP_EXTERNAL_TRIGGER\` matches current external release; skipping trigger." >> $GITHUB_STEP_SUMMARY
exit 0
fi
if [ -z "${EXT_RELEASE}" ] || [ "${EXT_RELEASE}" == "null" ]; then
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
echo "> Can't retrieve external version, exiting" >> $GITHUB_STEP_SUMMARY

View file

@ -17,6 +17,7 @@ RUN \
echo "**** install packages ****" && \
apt-get update && \
apt-get install --no-install-recommends -y \
gettext \
jsvc \
logrotate \
openjdk-17-jre-headless \

View file

@ -17,6 +17,7 @@ RUN \
echo "**** install packages ****" && \
apt-get update && \
apt-get install --no-install-recommends -y \
gettext \
jsvc \
logrotate \
openjdk-17-jre-headless \

33
Jenkinsfile vendored
View file

@ -56,11 +56,21 @@ pipeline {
steps{
echo "Running on node: ${NODE_NAME}"
sh '''#! /bin/bash
containers=$(docker ps -aq)
echo "Pruning builder"
docker builder prune -f --builder container || :
containers=$(docker ps -q)
if [[ -n "${containers}" ]]; then
docker stop ${containers}
BUILDX_CONTAINER_ID=$(docker ps -qf 'name=buildx_buildkit')
for container in ${containers}; do
if [[ "${container}" == "${BUILDX_CONTAINER_ID}" ]]; then
echo "skipping buildx container in docker stop"
else
echo "Stopping container ${container}"
docker stop ${container}
fi
done
fi
docker system prune -af --volumes || : '''
docker system prune -f --volumes || : '''
script{
env.EXIT_STATUS = ''
env.LS_RELEASE = sh(
@ -1152,12 +1162,21 @@ EOF
}
cleanup {
sh '''#! /bin/bash
echo "Performing docker system prune!!"
containers=$(docker ps -aq)
echo "Pruning builder!!"
docker builder prune -f --builder container || :
containers=$(docker ps -q)
if [[ -n "${containers}" ]]; then
docker stop ${containers}
BUILDX_CONTAINER_ID=$(docker ps -qf 'name=buildx_buildkit')
for container in ${containers}; do
if [[ "${container}" == "${BUILDX_CONTAINER_ID}" ]]; then
echo "skipping buildx container in docker stop"
else
echo "Stopping container ${container}"
docker stop ${container}
fi
done
fi
docker system prune -af --volumes || :
docker system prune -f --volumes || :
'''
cleanWs()
}

View file

@ -3,7 +3,7 @@
[![linuxserver.io](https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/linuxserver_medium.png)](https://linuxserver.io)
[![Blog](https://img.shields.io/static/v1.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=linuxserver.io&message=Blog)](https://blog.linuxserver.io "all the things you can do with our containers including How-To guides, opinions and much more!")
[![Discord](https://img.shields.io/discord/354974912613449730.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=Discord&logo=discord)](https://discord.gg/YWrKVTn "realtime support / chat with the community and the team.")
[![Discord](https://img.shields.io/discord/354974912613449730.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=Discord&logo=discord)](https://linuxserver.io/discord "realtime support / chat with the community and the team.")
[![Discourse](https://img.shields.io/discourse/https/discourse.linuxserver.io/topics.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&logo=discourse)](https://discourse.linuxserver.io "post on our community forum.")
[![Fleet](https://img.shields.io/static/v1.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=linuxserver.io&message=Fleet)](https://fleet.linuxserver.io "an online web interface which displays all of our maintained images.")
[![GitHub](https://img.shields.io/static/v1.svg?color=94398d&labelColor=555555&logoColor=ffffff&style=for-the-badge&label=linuxserver.io&message=GitHub&logo=github)](https://github.com/linuxserver "view the source for all of our repositories.")
@ -20,7 +20,7 @@ The [LinuxServer.io](https://linuxserver.io) team brings you another container r
Find us at:
* [Blog](https://blog.linuxserver.io) - all the things you can do with our containers including How-To guides, opinions and much more!
* [Discord](https://discord.gg/YWrKVTn) - realtime support / chat with the community and the team.
* [Discord](https://linuxserver.io/discord) - realtime support / chat with the community and the team.
* [Discourse](https://discourse.linuxserver.io) - post on our community forum.
* [Fleet](https://fleet.linuxserver.io) - an online web interface which displays all of our maintained images.
* [GitHub](https://github.com/linuxserver) - view the source for all of our repositories.
@ -204,10 +204,8 @@ docker run -d \
-e PUID=1000 \
-e PGID=1000 \
-e TZ=Etc/UTC \
-e MONGO_USER=unifi \
-e MONGO_PASS= \
-e MONGO_HOST=unifi-db \
-e MONGO_PORT=27017 \
-e MONGO_URI=mongodb+srv://unifi:password@unifi.mongodb.net/?retryWrites=true&w=majority&appName=unifi \
-e STAT_MONGO_URI=mongodb+srv://unifi:password@unifi.mongodb.net/?retryWrites=true&w=majority&appName=unifi \
-e MONGO_DBNAME=unifi \
-e MONGO_AUTHSOURCE=admin \
-e MEM_LIMIT=1024 `#optional` \

View file

@ -23,7 +23,7 @@ bash 5.2.21-2ubuntu4 deb
bcpkix-jdk18on 1.75 java-archive
bcprov-jdk18on 1.75 java-archive
bcutil-jdk18on 1.75 java-archive
bsdutils 1:2.39.3-9ubuntu6.1 deb
bsdutils 1:2.39.3-9ubuntu6.2 deb
bson 4.11.5 java-archive
bson-record-codec 4.11.5 java-archive
ca-certificates 20240203 deb
@ -155,17 +155,17 @@ lazysodium-java 5.1.4 jav
libacl1 2.3.2-1build1.1 deb
libapt-pkg6.0t64 2.7.14build2 deb
libassuan0 2.5.6-1build1 deb
libattr1 1:2.5.2-1build1 deb
libattr1 1:2.5.2-1build1.1 deb
libaudit-common 1:3.1.2-2.1build1.1 deb
libaudit1 1:3.1.2-2.1build1.1 deb
libblkid1 2.39.3-9ubuntu6.1 deb
libblkid1 2.39.3-9ubuntu6.2 deb
libbrotli1 1.1.0-2build2 deb
libbsd0 0.12.1-1build1 deb
libbsd0 0.12.1-1build1.1 deb
libbz2-1.0 1.0.8-5.1build0.1 deb
libc-bin 2.39-0ubuntu8.3 deb
libc6 2.39-0ubuntu8.3 deb
libcap-ng0 0.8.4-2build2 deb
libcap2 1:2.66-5ubuntu2 deb
libcap2 1:2.66-5ubuntu2.1 deb
libcom-err2 1.47.0-2.4~exp1ubuntu4.1 deb
libcommons-daemon-java 1.0.15-11build1 deb
libcrypt1 1:4.4.36-4build1 deb
@ -176,12 +176,12 @@ libext2fs2t64 1.47.0-2.4~exp1ubuntu4.1 deb
libffi8 3.4.6-1build1 deb
libgcc-s1 14.2.0-4ubuntu2~24.04 deb
libgcrypt20 1.10.3-2build1 deb
libgmp10 2:6.3.0+dfsg-2ubuntu6 deb
libgmp10 2:6.3.0+dfsg-2ubuntu6.1 deb
libgnutls30t64 3.8.3-1.1ubuntu3.2 deb
libgpg-error0 1.47-3build2 deb
libgpg-error0 1.47-3build2.1 deb
libgssapi-krb5-2 1.20.1-6ubuntu2.2 deb
libhogweed6t64 3.9.1-2.2build1.1 deb
libidn2-0 2.3.7-2build1 deb
libidn2-0 2.3.7-2build1.1 deb
libjpeg-turbo8 2.1.5-2ubuntu2 deb
libjpeg8 8c-2ubuntu11 deb
libjq1 1.7.1-3build1 deb
@ -195,11 +195,11 @@ libldap-common 2.6.7+dfsg-1~exp1ubuntu8.1 deb
libldap2 2.6.7+dfsg-1~exp1ubuntu8.1 deb
liblz4-1 1.9.4-1build1.1 deb
liblzma5 5.6.1+really5.4.5-1build0.1 deb
libmd0 1.1.0-2build1 deb
libmount1 2.39.3-9ubuntu6.1 deb
libmd0 1.1.0-2build1.1 deb
libmount1 2.39.3-9ubuntu6.2 deb
libncursesw6 6.4+20240113-1ubuntu2 deb
libnettle8t64 3.9.1-2.2build1.1 deb
libnghttp2-14 1.59.0-1ubuntu0.1 deb
libnghttp2-14 1.59.0-1ubuntu0.2 deb
libnpth0t64 1.6-3.1build1 deb
libnspr4 2:4.35-1.1build1 deb
libnss3 2:3.98-1build1 deb
@ -209,7 +209,7 @@ libpam-modules 1.5.3-5ubuntu5.1 deb
libpam-modules-bin 1.5.3-5ubuntu5.1 deb
libpam-runtime 1.5.3-5ubuntu5.1 deb
libpam0g 1.5.3-5ubuntu5.1 deb
libpcre2-8-0 10.42-4ubuntu2 deb
libpcre2-8-0 10.42-4ubuntu2.1 deb
libpcsclite1 2.0.3-1build1 deb
libpopt0 1.19+dfsg-1build1 deb
libproc2-0 2:4.0.4-4ubuntu3.2 deb
@ -220,12 +220,12 @@ libsasl2-2 2.1.28+dfsg1-5ubuntu3.1 deb
libsasl2-modules 2.1.28+dfsg1-5ubuntu3.1 deb
libsasl2-modules-db 2.1.28+dfsg1-5ubuntu3.1 deb
libseccomp2 2.5.5-1ubuntu3.1 deb
libselinux1 3.5-2ubuntu2 deb
libselinux1 3.5-2ubuntu2.1 deb
libsemanage-common 3.5-1build5 deb
libsemanage2 3.5-1build5 deb
libsepol2 3.5-2build1 deb
libsmartcols1 2.39.3-9ubuntu6.1 deb
libsqlite3-0 3.45.1-1ubuntu2 deb
libsmartcols1 2.39.3-9ubuntu6.2 deb
libsqlite3-0 3.45.1-1ubuntu2.1 deb
libss2 1.47.0-2.4~exp1ubuntu4.1 deb
libssh-4 0.10.6-2build2 deb
libssl3t64 3.0.13-0ubuntu3.4 deb
@ -234,8 +234,8 @@ libsystemd0 255.4-1ubuntu8.4 deb
libtasn1-6 4.19.0-3build1 deb
libtinfo6 6.4+20240113-1ubuntu2 deb
libudev1 255.4-1ubuntu8.4 deb
libunistring5 1.1-2build1 deb
libuuid1 2.39.3-9ubuntu6.1 deb
libunistring5 1.1-2build1.1 deb
libuuid1 2.39.3-9ubuntu6.2 deb
libxxhash0 0.8.2-2build1 deb
libzstd1 1.5.5+dfsg2-2build1.1 deb
locales 2.39-0ubuntu8.3 deb
@ -255,7 +255,7 @@ micrometer-observation 1.12.13 jav
minimal-json 0.9.5 java-archive
mongodb-driver-core 4.11.5 java-archive
mongodb-driver-sync 4.11.5 java-archive
mount 2.39.3-9ubuntu6.1 deb
mount 2.39.3-9ubuntu6.2 deb
ncurses-base 6.4+20240113-1ubuntu2 deb
ncurses-bin 6.4+20240113-1ubuntu2 deb
netcat-openbsd 1.226-1ubuntu2 deb
@ -265,7 +265,7 @@ openssl 3.0.13-0ubuntu3.4 deb
org.eclipse.paho.client.mqttv3 1.1.0 java-archive
owasp-java-html-sanitizer 20240325.1 java-archive
passwd 1:4.13+dfsg1-4ubuntu3.2 deb
perl-base 5.38.2-3.2build2 deb
perl-base 5.38.2-3.2build2.1 deb
pinentry-curses 1.2.1-3ubuntu5 deb
pop3 2.0.3 java-archive
procps 2:4.0.4-4ubuntu3.2 deb
@ -322,9 +322,10 @@ tomcat-embed-websocket 10.1.33 jav
txw2 4.0.5 java-archive
tzdata 2024a-3ubuntu1.1 deb
ubuntu-keyring 2023.11.28.1 deb
unminimize 0.2.1 deb
unzip 6.0-28ubuntu4.1 deb
urlrewritefilter 4.0.4.1 java-archive
util-linux 2.39.3-9ubuntu6.1 deb
util-linux 2.39.3-9ubuntu6.2 deb
xpp3 1.1.4c java-archive
xsdlib 2013.6.1 java-archive
zlib1g 1:1.3.dfsg-3.1ubuntu2.1 deb

View file

@ -6,6 +6,7 @@ project_url: "https://ui.com/"
project_logo: "https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/unifi-banner.png"
project_blurb: "The [{{ project_name|capitalize }}]({{ project_url }}) software is a powerful, enterprise wireless software engine ideal for high-density client deployments requiring low latency and high uptime performance."
project_lsio_github_repo_url: "https://github.com/linuxserver/docker-{{ project_name }}"
project_categories: "Network"
# supported architectures
available_architectures:
- {arch: "{{ arch_x86_64 }}", tag: "amd64-latest"}
@ -175,6 +176,7 @@ init_diagram: |
"unifi-network-application:latest" <- Base Images
# changelog
changelogs:
- {date: "23.12.24:", desc: "Change environment variables" }
- {date: "11.08.24:", desc: "**Important**: The mongodb init instructions have been updated to enable auth ([RBAC](https://www.mongodb.com/docs/manual/core/authorization/#role-based-access-control)). We have been notified that if RBAC is not enabled, the official mongodb container allows remote access to the db contents over port 27017 without credentials. If you set up the mongodb container with the old instructions we provided, you should not map or expose port 27017. If you would like to enable auth, the easiest way is to create new instances of both unifi and mongodb with the new instructions and restore unifi from a backup."}
- {date: "11.08.24:", desc: "Rebase to Ubuntu Noble."}
- {date: "04.03.24:", desc: "Install from zip package instead of deb."}

View file

@ -41,6 +41,6 @@
# unifi.throughput.port=6789
#
db.mongo.local=false
db.mongo.uri=mongodb://~MONGO_USER~:~MONGO_PASS~@~MONGO_HOST~:~MONGO_PORT~/~MONGO_DBNAME~?tls=~MONGO_TLS~~MONGO_AUTHSOURCE~
statdb.mongo.uri=mongodb://~MONGO_USER~:~MONGO_PASS~@~MONGO_HOST~:~MONGO_PORT~/~MONGO_DBNAME~_stat?tls=~MONGO_TLS~~MONGO_AUTHSOURCE~
unifi.db.name=~MONGO_DBNAME~
db.mongo.uri=$MONGO_URI
statdb.mongo.uri=$STAT_MONGO_URI
unifi.db.name=$MONGO_DBNAME

View file

@ -28,39 +28,11 @@ if [[ ! -L "/usr/lib/unifi/run" ]]; then
fi
if [[ ! -e /config/data/system.properties ]]; then
if [[ -z "${MONGO_HOST}" ]]; then
echo "*** No MONGO_HOST set, cannot configure database settings. ***"
if [[ -z "${MONGO_URI}" || -z "${STAT_MONGO_URI}" || -z "${MONGO_DBNAME}" ]]; then
echo "*** Required environment variables are not set, cannot configure database settings. ***"
sleep infinity
else
echo "*** Waiting for MONGO_HOST ${MONGO_HOST} to be reachable. ***"
DBCOUNT=0
while true; do
if nc -w1 "${MONGO_HOST}" "${MONGO_PORT}" >/dev/null 2>&1; then
break
fi
DBCOUNT=$((DBCOUNT+1))
if [[ ${DBCOUNT} -gt 6 ]]; then
echo "*** Defined MONGO_HOST ${MONGO_HOST} is not reachable, cannot proceed. ***"
sleep infinity
fi
sleep 5
done
sed -i "s/~MONGO_USER~/${MONGO_USER}/" /defaults/system.properties
sed -i "s/~MONGO_HOST~/${MONGO_HOST}/" /defaults/system.properties
sed -i "s/~MONGO_PORT~/${MONGO_PORT}/" /defaults/system.properties
sed -i "s/~MONGO_DBNAME~/${MONGO_DBNAME}/" /defaults/system.properties
sed -i "s/~MONGO_PASS~/${MONGO_PASS}/" /defaults/system.properties
if [[ "${MONGO_TLS,,}" = "true" ]]; then
sed -i "s/~MONGO_TLS~/true/" /defaults/system.properties
else
sed -i "s/~MONGO_TLS~/false/" /defaults/system.properties
fi
if [[ -z "${MONGO_AUTHSOURCE}" ]]; then
sed -i "s/~MONGO_AUTHSOURCE~//" /defaults/system.properties
else
sed -i "s/~MONGO_AUTHSOURCE~/\&authSource=${MONGO_AUTHSOURCE}/" /defaults/system.properties
fi
cp /defaults/system.properties /config/data
envsubst < /defaults/system.properties > /config/data/system.properties
fi
fi