diff options
author | Mike Crute <mike@crute.us> | 2022-12-03 15:56:16 -0800 |
---|---|---|
committer | Mike Crute <mike@crute.us> | 2022-12-03 15:56:16 -0800 |
commit | a22e5d1743e02a578da5b8cc305de18f180f5c5f (patch) | |
tree | 52f2a8bc0c21222450fa468d877bd0784cf48fe8 | |
parent | 245cf4f44375a7ae2a51d7412a94f46acad2c648 (diff) | |
download | dockerfiles-a22e5d1743e02a578da5b8cc305de18f180f5c5f.tar.bz2 dockerfiles-a22e5d1743e02a578da5b8cc305de18f180f5c5f.tar.xz dockerfiles-a22e5d1743e02a578da5b8cc305de18f180f5c5f.zip |
unifi: update to 7.2.91
-rw-r--r-- | unifi/Makefile | 6 | ||||
-rw-r--r-- | unifi/Makefile5 | 36 | ||||
-rwxr-xr-x | unifi/entrypoint.sh | 11 |
3 files changed, 51 insertions, 2 deletions
diff --git a/unifi/Makefile b/unifi/Makefile index 67d3763..83e2fc9 100644 --- a/unifi/Makefile +++ b/unifi/Makefile | |||
@@ -1,9 +1,9 @@ | |||
1 | VERSION=5.14.23 | 1 | VERSION=7.2.91-85c367a4aa |
2 | IMAGE=docker.crute.me/unifi:$(VERSION) | 2 | IMAGE=docker.crute.me/unifi:$(VERSION) |
3 | LATEST=$(subst :$(VERSION),,$(IMAGE)):latest | 3 | LATEST=$(subst :$(VERSION),,$(IMAGE)):latest |
4 | 4 | ||
5 | DEB_LOCATION="https://dl.ui.com/unifi/$(VERSION)/unifi_sysvinit_all.deb" | 5 | DEB_LOCATION="https://dl.ui.com/unifi/$(VERSION)/unifi_sysvinit_all.deb" |
6 | CHECKSUM_LINE="fb12d448828656523978be9f594f2ce3fb35d524bc80d2c150e58f2a7d0159a9 *unifi_sysvinit_all.deb" | 6 | CHECKSUM_LINE="d33e7b5a838a4c301ca545910e7119ba62bda80202259655191ced1e482cecde *unifi_sysvinit_all.deb" |
7 | 7 | ||
8 | all: | 8 | all: |
9 | docker pull alpine:latest | 9 | docker pull alpine:latest |
@@ -30,5 +30,7 @@ run: | |||
30 | 30 | ||
31 | publish: | 31 | publish: |
32 | docker push $(IMAGE) | 32 | docker push $(IMAGE) |
33 | |||
34 | publish-prod: | ||
33 | docker tag $(IMAGE) $(LATEST) | 35 | docker tag $(IMAGE) $(LATEST) |
34 | docker push $(LATEST) | 36 | docker push $(LATEST) |
diff --git a/unifi/Makefile5 b/unifi/Makefile5 new file mode 100644 index 0000000..7c2c212 --- /dev/null +++ b/unifi/Makefile5 | |||
@@ -0,0 +1,36 @@ | |||
1 | VERSION=5.14.23 | ||
2 | IMAGE=docker.crute.me/unifi:$(VERSION) | ||
3 | LATEST=$(subst :$(VERSION),,$(IMAGE)):latest | ||
4 | |||
5 | DEB_LOCATION="https://dl.ui.com/unifi/$(VERSION)/unifi_sysvinit_all.deb" | ||
6 | CHECKSUM_LINE="fb12d448828656523978be9f594f2ce3fb35d524bc80d2c150e58f2a7d0159a9 *unifi_sysvinit_all.deb" | ||
7 | |||
8 | all: | ||
9 | docker pull alpine:latest | ||
10 | docker build \ | ||
11 | --no-cache \ | ||
12 | --build-arg=deb_location=$(DEB_LOCATION) \ | ||
13 | --build-arg=checksum_line=$(CHECKSUM_LINE) \ | ||
14 | -t $(IMAGE) . | ||
15 | |||
16 | all-no-cache: | ||
17 | docker build \ | ||
18 | --no-cache \ | ||
19 | --build-arg=deb_location=$(DEB_LOCATION) \ | ||
20 | --build-arg=checksum_line=$(CHECKSUM_LINE) \ | ||
21 | -t $(IMAGE) . | ||
22 | |||
23 | run: | ||
24 | docker run -d \ | ||
25 | -e UNIFI_UID=1001 \ | ||
26 | -e UNIFI_GID=1001 \ | ||
27 | -p 8080:8080 \ | ||
28 | -p 8443:8443 \ | ||
29 | $(IMAGE) | ||
30 | |||
31 | publish: | ||
32 | docker push $(IMAGE) | ||
33 | |||
34 | publish-prod: | ||
35 | docker tag $(IMAGE) $(LATEST) | ||
36 | docker push $(LATEST) | ||
diff --git a/unifi/entrypoint.sh b/unifi/entrypoint.sh index f431c4f..506c20f 100755 --- a/unifi/entrypoint.sh +++ b/unifi/entrypoint.sh | |||
@@ -44,6 +44,16 @@ if [ -n "$MONGO_URL" ]; then | |||
44 | echo "db.mongo.uri=${MONGO_URL}" >> /var/lib/unifi/system.properties | 44 | echo "db.mongo.uri=${MONGO_URL}" >> /var/lib/unifi/system.properties |
45 | echo "statdb.mongo.uri=${MONGO_STATS_URL}" >> /var/lib/unifi/system.properties | 45 | echo "statdb.mongo.uri=${MONGO_STATS_URL}" >> /var/lib/unifi/system.properties |
46 | echo "unifi.db.name=${MONGO_DB_NAME:-ace}" >> /var/lib/unifi/system.properties | 46 | echo "unifi.db.name=${MONGO_DB_NAME:-ace}" >> /var/lib/unifi/system.properties |
47 | echo "statdb.db.name=${MONGO_STATS_DB_NAME:-ace_stat}" >> /var/lib/unifi/system.properties | ||
48 | fi | ||
49 | |||
50 | # If this is set that the controller will start with no settings and will run | ||
51 | # the setup. | ||
52 | # | ||
53 | # WARNING! If this is set on a live database then the controller will delete | ||
54 | # all data and start fresh. | ||
55 | if [ -z "$START_DEFAULT" ]; then | ||
56 | echo "is_default=false" >> /var/lib/unifi/system.properties | ||
47 | fi | 57 | fi |
48 | 58 | ||
49 | # Allow running a shell in the container | 59 | # Allow running a shell in the container |
@@ -60,6 +70,7 @@ else | |||
60 | exec /usr/bin/dumb-init -c /sbin/su-exec ${USERNAME} /usr/lib/jvm/default-jvm/bin/java \ | 70 | exec /usr/bin/dumb-init -c /sbin/su-exec ${USERNAME} /usr/lib/jvm/default-jvm/bin/java \ |
61 | -cp ${BASEDIR}/lib/ace.jar \ | 71 | -cp ${BASEDIR}/lib/ace.jar \ |
62 | -Dlog4j.configuration=file:${BASEDIR}/log4j.properties \ | 72 | -Dlog4j.configuration=file:${BASEDIR}/log4j.properties \ |
73 | -Dlog4j2.formatMsgNoLookups=true \ | ||
63 | -Dunifi.datadir=${BASEDIR}/data \ | 74 | -Dunifi.datadir=${BASEDIR}/data \ |
64 | -Dunifi.logdir=${BASEDIR}/logs \ | 75 | -Dunifi.logdir=${BASEDIR}/logs \ |
65 | -Dunifi.rundir=${BASEDIR}/run \ | 76 | -Dunifi.rundir=${BASEDIR}/run \ |