Hi!
I rebooted my server and AzuraCast now looks funky (dark theme isn't working, managing stations shows a blue menu bar etc). No clue how it happend, but guess 'shit happend'.
I would like to start fresh with a Docker installation (read in the releases that new installations of traditional/barebones isn't supported), but I currently still have a kinda-working barebones version.
Ideally I would want to move everything to a new VM with a clean installation of Ubuntu Server.
My question is: is there the possibility to migrate the configs/databases to a new server? I don't mind losing the songs, I can easily re-upload them.
You could use our docker-migrate.sh to first migrate your existing installation to Docker and then use our backup command to create a backup of your Docker installation and use that to restore your Docker installation on your new VM.
Regarding the blue bars, we recently introduced some bigger UI improvements that also included some coloring for card headers. Why your dark theme stopped working though that's not intended and I'm not sure whats going on there.
Great! Is there a way to restore only the config though? And not AzuraCast itself?
I want to fully reinstall Azura, but I want to keep the configs and streamer accounts.
I want to fix the dark theme, and I'm not sure if it gets fixed by migrating it to Docker.
EDIT: I ran the migration script, but at the end it gave an error about not enough free disk space. I had 10 GB free before I ran the migration script, I was not aware that it was using that much space to migrate it to Docker.
My AzuraCast is completely broken. I'm going to restore a snapshot of the VM.
EDIT2: Did a 2nd attempt of migrating it to Docker. I cleared up some unused files and it was succesfully installed. However, it's unable to play songs (keeps saying the 'welcome to azuracast' jingle) and if I press on Music Files, I get a 500 error. Theme still looks fugged-up (https://share.pilovali.nl/1t83dTbb.png).
I'm going to restore the snapshot again, so it's working again.
Can someone assist me with this issue?
The migration itself shouldn't take too much space overall the Docker containers however should come around to about 1 GB. But operating with such low space available is pretty risky anyways in my opinion so you may want to make sure that you have a few GB of free space available after uploading all your audio files.
The script creates a backup of the MariaDB and InfluxDB, downloads and installs Docker + Docker Compose, downloads the Docker containers and sets them up with the backups and moves the station data over to it (no copy, so that doesn't duplicate data).
The containers currently have the following sizes:
Radio = 232 MB
Web = 368 MB
MariaDB = 115 MB
Redis = 18 MB
InfluxDB = 29 MB
Stations = 444 MB
Regarding the 500 error, take a look at docker logs azuracast_web_1 and look for error details there and post them here.
About the theme issues, I've never seen that before. Are there any errors in your browsers JS console?
I actually had 2.5 GB free. Whoops.
I'm going to create a clone of the VM and try to get it working before trying to upgrade the production server, hehe.
I'll post the logs when I migrated the cloned VM.
Ok, I've cloned it. It looks like I'm not getting any errors anymore (I guess it was because I forgot to attach the right storage drive, oops), but the theme is still messed up.
https://share.pilovali.nl/7y67bTcb.png
I don't see any errors in the console. If you want, I could give you login details, so you can poke around.
@pilovali You can send me the login details to my E-Mail address: [email protected]
@pilovali You can send me the login details to my E-Mail address: [email protected]
Done.
The theme issues are coming from your Custom CSS for Internal Pages. Try removing the CSS completely (save it somewhere), see how it looks now without it and re-apply selectively what you need and see if anything doesn't work as expected anymore. As this is custom work you'll have to do this on your own but if you're stuck somewhere I can help you figure it out.
The 500 error is most likely due to the media directory settings of the stations where that error is showing up. The mounted directory that the stations point to is not mounted in the server. You'll have to mount them then it should work again. Also pay attention to the permissions of the mounted directories so that the files are accessible for AzuraCast. You may also have to manually run the Media Sync task after mounting them to index these directories.
The theme issues are coming from your
Custom CSS for Internal Pages. Try removing the CSS completely (save it somewhere), see how it looks now without it and re-apply selectively what you need and see if anything doesn't work as expected anymore. As this is custom work you'll have to do this on your own but if you're stuck somewhere I can help you figure it out.The
500error is most likely due to the media directory settings of the stations where that error is showing up. The mounted directory that the stations point to is not mounted in the server. You'll have to mount them then it should work again. Also pay attention to the permissions of the mounted directories so that the files are accessible for AzuraCast. You may also have to manually run the Media Sync task after mounting them to index these directories.
Oh daaauym, it's working. I can't remember changing the CSS though, maybe one of the other administrators did... (small feature request: pls add audit logs for Azura, so superadmins can see what people are doing).
Thanks a bunch. Gonna try to migrate the production server to Docker again and see what happens.
@pilovali Would you mind creating a feature request for that over at https://features.azuracast.com/ ? That way other users can vote for it so that we have an indication how important it is to our users in comparison to other features. That helps us prioritise them.
I've created a feature request, and I'm now busy with migrating it to Docker.
May 18 18:10:59 f6e4e238c562 php-fpm[52]: [WARNING] [pool www] child 66 said into stderr: "[2019-05-18 18:10:59] AzuraCast.ERROR: Impossible to create the root directory "/mnt/HC_Volume_1530422/Rap". mkdir(): Permission denied {"file":"/var/azuracast/www/vendor/league/flysystem/src/Adapter/Local.php","line":113,"code":0} []"
@Vaalyn I'm unable to make the other stations work. The mount exist. What do I do wrong here?
@pilovali As the error says Permission denied for the directory /mnt/HC_Volume_1530422 make sure that the directory is mounted to the stations and web containers and that the PHP process is able to write to that directory.
@pilovali As the error says
Permission deniedfor the directory/mnt/HC_Volume_1530422make sure that the directory is mounted to the stations and web containers and that the PHP process is able to write to that directory.
It worked before without issues. I'm new to Docker, do I need to do something inside Docker in order to mount it? Do I need to chown it?
And I'm also unable to create a Let's Encrypt certificate:
root@azura:/var/azuracast/www# ./docker.sh letsencrypt-create azura.xxxx.net
Traceback (most recent call last):
File "/usr/bin/certbot", line 11, in
load_entry_point('certbot==0.31.0', 'console_scripts', 'certbot')()
File "/usr/lib/python3/dist-packages/certbot/main.py", line 1333, in main
log.pre_arg_parse_setup()
File "/usr/lib/python3/dist-packages/certbot/log.py", line 55, in pre_arg_parse_setup
temp_handler = TempHandler()
File "/usr/lib/python3/dist-packages/certbot/log.py", line 243, in __init__
stream = tempfile.NamedTemporaryFile('w', delete=False)
File "/usr/lib/python3.6/tempfile.py", line 679, in NamedTemporaryFile
prefix, suffix, dir, output_type = _sanitize_params(prefix, suffix, dir)
File "/usr/lib/python3.6/tempfile.py", line 269, in _sanitize_params
dir = gettempdir()
File "/usr/lib/python3.6/tempfile.py", line 435, in gettempdir
tempdir = _get_default_tempdir()
File "/usr/lib/python3.6/tempfile.py", line 370, in _get_default_tempdir
dirlist)
FileNotFoundError: [Errno 2] No usable temporary directory found in ['/tmp', '/var/tmp', '/usr/tmp', '/var/azuracast/www']
Domain name azura.xxxx.net is not set up with LetsEncrypt yet. Reverting to self-signed cert...
Generating a 2048 bit RSA private key
...................................................................................................................................................................+++
.......+++writing new private key to '/etc/letsencrypt/selfsigned.key'
Self-signed certificate restored.
root@azura:/var/azuracast/www#
EDIT: moments after posting the above log, I see this when I press on the home: https://share.pilovali.nl/40505T0b.png
I guess I gotta restore the snapshot. Something is wrong.
You should create a docker-compose.override.yml alongside the docker-compose.yml and mount the directory to the services I mentioned. The file should look something like this:
version: '2.2'
services:
web:
volumes:
- /mnt/HC_Volume_1530422:/mnt/HC_Volume_1530422
stations:
volumes:
- /mnt/HC_Volume_1530422:/mnt/HC_Volume_1530422
You'll need to restart the AzuraCast to apply this.
Thanks, I'll do an other attempt tomorrow, sorry.
The Ansible version is, _in my opinion_ easier, but that's probably because I have no experiences with Docker.
Oh, and what about Let's Encrypt and the screenshot I've posted above?
At the beginning Docker might be a bit harder if you've never used it before but once you know the basics it's pretty easy and actually much more enjoyable to use than installing stuff directly on your server.
I'm not really sure what's going on with the Let's Encrypt setup there. I've not seen that error before. @SlvrEagle23 Do you have an idea what's happening there?
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.