Author: abhijit

upgrading bitwarden / vaultwarden

I had posted earlier about running Vaultwarden (a Bitwarden server in Rust). This has been running amazingly all this time.

But today, when I tried to log in from the browser extension, I kept getting an error.

Searching in the forum, I found the issue – I had to update the Vaultwarden server.

Since I was running Vaultwarden as a Docker container, and I had run the docker command directly, so I decided to create a docker-compose.yml file instead this time.

Continue reading

Nginx – folders as subdomains

I have a projects folder in which I put multiple folders, each having an html page.

So, the folder hierarchy looks something like this –

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
projects
|-sampleproject1
|-index.html
|-style.css
|-sampleproject2
|-index.html
|-style.css
projects |-sampleproject1 |-index.html |-style.css |-sampleproject2 |-index.html |-style.css
projects
|-sampleproject1
  |-index.html
  |-style.css
|-sampleproject2
  |-index.html
  |-style.css

I want to have each of these folders as subdomains to my domain, so I had to create an nginx conf file for each one with a different root path.

I was looking for way to have this done automatically using Nginx and finally found it!

Continue reading

error – sudo without being in the sudo group?

This was quite a head-scratcher. I wanted to remove a user sammy from the sudo group and did that by running this as root

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
root> deluser sammy sudo
root> deluser sammy sudo
root> deluser sammy sudo

However, when I logged in as sammy I was still able to run –

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
sammy> sudo su
sammy> sudo su
sammy> sudo su

Checking which groups the user belonged to was of no help either.

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
sammy> groups
sammy
sammy> groups sammy
sammy> groups
sammy
Continue reading

Postgres pg_dump without password

I have to do a dump of a Postgres database on a regular basis.

So pg_dump is the obvious choice to do this as is cron to do this periodically.

But the main problem with this is – pg_dump expects a password to be entered at the prompt. There’s no way to pass the password in the prompt to be able to do this.

Stackoverflow to the rescue.

What is required is a .pgpass file in the home directory.

Continue reading

‘asdf’ not finding program

I discovered asdf quite late! I was relying on a bunch of different programs to manage Ruby (rvm), Node (nvm).

asdf was an amazing headache saver. It already has core plugins for Elixir, Erlang, Node and Ruby. Plus, it has community plugins for what seems like practically anything under the sun.

I had installed asdf on a new system. And as usual, there were some crons to run on it. I kept getting a /bin/bash/ruby not found error.

After some time I realized I had faced this problem before as well!

Continue reading

Connect to server running on host from inside a Docker container

After installing the CloudBeaver as a Docker instance, I was trying to connect to the Postgres instance which I was running on my local machine.

In the HOST field, I tried with localhost which obviously wouldn’t work since that refers to the VM itself.

After some searching I found that to connect to the host, I need to set the connection as

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
host.docker.internal
host.docker.internal
host.docker.internal

Copyright © 2025 the möbius trip

Theme by Anders NorenUp ↑