Files
truecharts/charts/stable/unifi/values.yaml
T
Kjeld SchoutenandGitHub f8e33766bf feat(common): remove portal and ensure appUrl is used for notes.txt (#34047)
**Description**

This removes old portal references (from truenas times) from common and
notes.txt
Also ensures chartContext is used for notes.txt

Technically breaking in case any down-stream users use portal
configmap/data

⚒️ Fixes  #31880

**⚙️ Type of change**

- [x] ⚙️ Feature/App addition
- [ ] 🪛 Bugfix
- [ ] ⚠️ Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- [x] 🔃 Refactor of current code
- [ ] 📜 Documentation Changes

**🧪 How Has This Been Tested?**
<!--
Please describe the tests that you ran to verify your changes. Provide
instructions so we can reproduce. Please also list any relevant details
for your test configuration
-->

**📃 Notes:**
<!-- Please enter any other relevant information here -->

**✔️ Checklist:**

- [ ] ⚖️ My code follows the style guidelines of this project
- [ ] 👀 I have performed a self-review of my own code
- [ ] #️⃣ I have commented my code, particularly in hard-to-understand
areas
- [ ] 📄 I have made changes to the documentation
- [ ] 🧪 I have added tests to this description that prove my fix is
effective or that my feature works
- [ ] ⬆️ I increased versions for any altered app according to semantic
versioning
- [ ] I made sure the title starts with `feat(chart-name):`,
`fix(chart-name):`, `chore(chart-name):`, `docs(chart-name):` or
`fix(docs):`

** App addition**

If this PR is an app addition please make sure you have done the
following.

- [ ] 🖼️ I have added an icon in the Chart's root directory called
`icon.png`

---

_Please don't blindly check all the boxes. Read them and only check
those that apply.
Those checkboxes are there for the reviewer to see what is this all
about and
the status of this PR with a quick glance._

---------

Signed-off-by: Kjeld Schouten <info@kjeldschouten.nl>
2025-04-07 22:04:57 +02:00

109 lines
2.6 KiB
YAML

image:
repository: ghcr.io/goofball222/unifi
tag: 9.0.114@sha256:80f7cec9c823477c7f12aa06f059db903dcdf5aeb9527aed2cf8dada9bdb46fe
pullPolicy: IfNotPresent
service:
main:
ports:
main:
protocol: https
port: 8443
targetPort: 8443
comm:
enabled: true
ports:
comm:
enabled: true
port: 8080
targetPort: 8080
stun:
enabled: true
ports:
stun:
enabled: true
port: 3478
targetPort: 3478
protocol: udp
speedtest:
enabled: true
ports:
speedtest:
enabled: true
port: 6789
targetPort: 6789
guestportal:
enabled: true
ports:
web:
enabled: true
port: 8880
targetPort: 8880
protocol: http
websecure:
enabled: true
port: 8843
targetPort: 8843
protocol: https
persistence:
config:
enabled: true
targetSelector:
main:
main:
mountPath: /usr/lib/unifi/olddata
migrate:
mountPath: /usr/lib/unifi/olddata
data:
enabled: true
targetSelector:
main:
main:
mountPath: /usr/lib/unifi/data
migrate:
mountPath: /usr/lib/unifi/data
logs:
enabled: true
mountPath: "/usr/lib/unifi/logs"
type: "emptyDir"
certs:
enabled: true
mountPath: "/usr/lib/unifi/cert"
securityContext:
container:
readOnlyRootFilesystem: false
runAsGroup: 0
runAsUser: 0
workload:
main:
podSpec:
containers:
main:
env:
RUN_CHOWN: true
DB_MONGO_LOCAL: true
initContainers:
migrate:
enabled: true
type: init
imageSelector: alpineImage
command:
- /bin/sh
args:
- -c
- |
newdatadir="/usr/lib/unifi/data"
olddatadir="/usr/lib/unifi/olddata/data"
# Check the dir exists
[ ! -d "$newdatadir" ] && echo "$newdatadir missing" && exit 1
# Check if there is a data/data dir to migrate
[ ! -d "$olddatadir" ] && echo "No $olddatadir dir found. Migration skipped" && exit 0
# Check if the new data dir is empty, ignoring the old data dir
dirs=$(ls -A "$newdatadir" | grep -v "data")
if [ -n "$dirs" ]; then
echo "New data dir is empty. Migrating data one level up"
cp -rf $olddatadir/* $newdatadir || echo "Failed to move data" && exit 1
echo "Data migration complete"
fi