heroiccocoa
Joined 5 years ago
Joined 5 years ago
I was like you with docker at the start of the week, I had managed to avoid it until now, but I didn't want to let agents do crazy sneaky stuff to my main system. VirtualBox, even with the guest additions just sucks as an environment to spend more than a few hours developing in, especially with how they take up precious RAM and VRAM that local LLMs need. Let me tell you: Docker for this use case at least turned out to be way easier than I thought! It only took me a few hours to really understand the main workflow for a basic project, docker is actually very nice to use, I should not have left it this long. With just a few commands I feel like I got enough sandboxing for my liking. For example, from my bash history yesterday:
docker run -it --rm archlinux
this gives you an interactive archlinux container, and destroys itself when you exit with ctrl+d. If you want to re-enter where you left off, you can attach or start the container again if you omit the --rm flag. docker build -t flask_test .
this builds a container tagged "flask_test" using Dockerfile in the current directory. Dockerfiles are quite simple FROM python:3-alpine
WORKDIR /my_app
RUN pip install flask
# copy app.py from the working directory to the container directory "."
COPY app.py .
# Make port 5000 available to the world outside this container
# this networking stuff is a bit of a mess to configure, you have to set it in flask, the Dockerfile, when you run the container, and you still get different URLs that the server is on, not all work on the host or the container, etc., it's a bit of a mess IMO. This turned out to not be necessary.
#EXPOSE 5000
# Define environment variable for Flask
ENV FLASK_APP=app.py
ENV FLASK_RUN_HOST=0.0.0.0
# run the command "flask" when the container starts with the "run" argument
CMD ["flask", "run"]
The docs are very extensive, and feature a lot of (for me, anyway) useless commands like "docker ps"
"docker images"
these are not that useful compared to this: docker container ls --all
which just shows everything.Then, to restart from where you exited the next day:
docker start -ia amazing_jemison
This resumes the "amazing_jemison" (randomly assigned name) container. You see the name under column in the previous ls --all command. I don't get why they use CONTAINER IDs so much in the docs instead of NAMES, because they don't feature tab autocomplete, requiring wasted effort copying long hexadecimal strings.I've been using throwaway archlinux docker containers all week, it's like a snappy VM, I just have to figure out how to launch graphics applications, although apparently that's an antipattern. I tried alpine, ubuntu, debian, etc., too, but archlinux is what I'm used to and the perfect balance between size and being feature-complete for me. Alpine boasts about the minimal image size but in reality you end up missing a lot of useful modern premium features that you have to redownload anyway. I never made a Dockerfile for it, it just downloaded the default archlinux image. After you exit out, and it selfdestructs with rm, and then you want to do it all again from scratch, as per the first command
docker run -it --rm archlinux
and it will use a locally cached version, saving Docker from having to redownloadOverall a very good experience.
[1] https://en.wikipedia.org/wiki/%CE%92-Hydroxy_%CE%B2-methylbu...
The software on their website was a Windows executable .exe file that seemed outdated even 10 years ago. To complete the last few steps, the printer network connection had to be set up once again, even though I had already previously connected it. Each attempt would take around 10-20 minutes, only to fail. The network errors and troubleshooting steps were incredibly generic and unhelpful. The worst part, until that point, was that the printer shipped with outdated firmware, and I did an online firmware update via the printer itself, confirming that the printer's Internet connection had indeed already been established. Rebooting the printer did not help. It turned out that, despite only just downloading the Windows executable that same hour from the Epson website, they were shipping an old version .exe, with some bug that causes the network setup to not be detected. However, it never prompted me to update. Only after restarting the Windows computer, and then re-opening the .exe, did some update trigger, and it allowed me to finish setting through to the last step of the installer to download the rest of the bloat and let the printer appear in the list of available printers on the network on the computer.
I then did a test print via an iPad. Took about 15 seconds.
You can also look at (670/810 nm LED light strips to hang above your computer monitors and passively absorb some while starting at your monitor all day if you are getting an excess of blue light). I think that is another protocol though, but it might help.
I am sure though that it's more about consistency and treatment time (as in, you can't double the intensity to halve the treatment time). Furthermore, more is not better, it's more like an on/off switch after 2-3 minutes. You can do it every day, just like the solar spectrum is relatively higher in the required part of the spectrum at early morning sunrise every day.
But honestly, listen to Glen Jeffery, perhaps read /r/redlighttherapy