dashy
dashy copied to clipboard
[BUG] No longer builds on startup
Environment
Self-Hosted (Docker)
System
Chrome 108 on Windows 10 - Docker 20.10.17 on Raspbian 11 bullseye
Version
2.1.1
Describe the problem
For a few versions now Dashy starts up and doesn't have my custom styles applied so I need to connect and run yarn build manually.
I have a file mounted at /app/src/styles/user-defined-themes.scss to apply my custom scss which used to work fine after updates, but now I need to trigger a manual build every container update.
My containers are automatically update using watchtowerr
Additional info
The below is the output of the container on start
yarn run v1.22.15
$ node server
Checking config file against schema...
✔️ Config file is valid, no issues found
██████╗ █████╗ ███████╗██╗ ██╗██╗ ██╗
██╔══██╗██╔══██╗██╔════╝██║ ██║╚██╗ ██╔╝
██║ ██║███████║███████╗███████║ ╚████╔╝
██║ ██║██╔══██║╚════██║██╔══██║ ╚██╔╝
██████╔╝██║ ██║███████║██║ ██║ ██║
╚═════╝ ╚═╝ ╚═╝╚══════╝╚═╝ ╚═╝ ╚═╝
*******************************************************************************************
Welcome to Dashy! 🚀
Your new dashboard is now up and running with Docker
*******************************************************************************************
🔐 HTTPS server successfully started (port: 443 of container)
Using Dashy V-2.1.1. Update Check Complete
✅ Dashy is Up-to-Date
Please tick the boxes
- [X] You have explained the issue clearly, and included all relevant info
- [X] You are using a supported version of Dashy
- [X] You've checked that this issue hasn't already been raised
- [X] You've checked the docs and troubleshooting guide
- [X] You agree to the code of conduct
I confirm this problem. You have to manually enter the container and run the yarn build command. Only then does Dashy rebuild and themes and configurations are applied. Multipages also don't work until you manually rebuild Dashy.
You may solve this by adding entrypoint: ["yarn","build-and-start"] to your docker-compose.yml. The drawback is whenever you click the "save on disk" button, it will build the whole project again. It can be CPU-consuming for some low-end VM. Hope there will be a more elegant way to solve this problem.
here is my docker-compose.yml version: "3.8"
services: dashy: container_name: Dashy hostname: dashy # Pull latest image from DockerHub image: lissy93/dashy:latest
# Pass in your config file below, by specifying the path on your host machine
volumes:
- /home/ubuntu/dashy/public:/app/public
- type: bind
source: /home/ubuntu/dashy/.env
target: /app/public/.env
entrypoint: ["yarn","build-and-start"]
# Set port that web service will be served on. Keep container port as 80
ports:
- 4000:80
# Set any environmental variables
environment:
- NODE_ENV=production
# Specify restart policy
restart: unless-stopped
# Configure healthchecks
healthcheck:
test: ['CMD', 'node', '/app/services/healthcheck']
interval: 1m30s
timeout: 10s
retries: 3
start_period: 40s
If I have time this weekend, I will write articles on how to build Dashy using docker & how to use Nginx Proxy Manager + Authelia for authentication.
Btw the solution to this issue was mentioned by coalwater. You may read the closed issue here.
This issue has gone 6 weeks without an update. To keep the ticket open, please indicate that it is still relevant in a comment below. Otherwise it will be closed in 5 working days.
This is still relevant and happens without changing entrypoint to yarn build-and-start
We will not wait for the developer's response, it seems. Is she too busy with other projects?
I confirm this problem. You have to manually enter the container and run the yarn build command. Only then does Dashy rebuild and themes and configurations are applied. Multipages also don't work until you manually rebuild Dashy.
Can confirm this still happens to me, after I added multiple pages.
Used the UI to make edits, save, refresh, and the edit is gone. Can confirm the config file is saved locally. I have to manually trigger the rebuild from the UI.
It still builds if I restart my docker, but having to restart or trigger manually each time I make edits via UI is annoying.
This issue has gone 6 weeks without an update. To keep the ticket open, please indicate that it is still relevant in a comment below. Otherwise it will be closed in 5 working days.
This is still relevant
I can confirm this is still relevant too.
Interestingly, this is a regression from 2.1.0.
Took a lot of head-scratching to understand why my Keycloak authentication configuration was not applying properly. It was caused because no build happens when the official Docker image is started.
In my opinion this issue becomes far more severe if my dashboard can become public-access if my Docker container gets recreated (without manually intervening and starting a build).
Further investigations:
I've narrowed down that this regressed in commit " 60d0b03: removed build watch and tini from container run-time".
It was pushed directly to master, so there is no linked PR or issue with more information about this change.
This change isn't in the 2.1.1 tag, so this shouldn't be an issue in the 2.1.1 docker image.
BUT.
I've noticed that the 2.1.1 Docker image was last updated 13 days ago and when viewing the Image Layer Details it seems to be executing commands as if using the master Dockerfile.
@Lissy93 Are you aware of an issue with the automated deployments deploying some form of master to the 2.1.1 tag on Docker Hub?
This issue has gone 3 months without an update. To keep the ticket open, please indicate that it is still relevant in a comment below. Otherwise it will be closed in 5 working days.
Still relevant. Waiting to hear back from @Lissy93.
This issue has gone 3 months without an update. To keep the ticket open, please indicate that it is still relevant in a comment below. Otherwise it will be closed in 5 working days.
Still relevant. Waiting to hear back from @Lissy93.
The fix for this issue has now been released in 2.1.2 ✨
If you haven't done so already, please update your instance to 2.1.2 or later. See 2.1.2 for full info.
Feel free to reach out if you need any more support. If you are enjoying Dashy, consider supporting the project.