Search

Search Code by entering the text above.
linux
certbot add a certificate for one domain
...

this adds a certificate for one domain and modifies the nginx config to use the certificate also giving you the option to redirect all traffic to the secure version

6:46 am, August 26, 2020
linux
renew all certificates with certbot
...

just issue the following command in bash

6:45 am, August 26, 2020
linux
To make Ubuntu do nothing when laptop lid is closed
...

sudo nano /etc/systemd/logind.confchange this to ignore: `HandleLidSwitch=ignore`save the filerestart the login daemon sudo service systemd-logind restart

12:50 am, July 27, 2020
linux
add a user to a group
...

usermod -a -G examplegroup exampleusername

3:00 am, July 12, 2020
linux
loop through each directory in a target directory and compress them
...

this one loops through each of the target directory and also compresses each one

2:55 am, July 12, 2020
linux
loop through each directory in a target directory
...

i thought this would be useful for backing up all files in the /var/www/html/ directory rather than having to do each seperately, this loops through all of them

2:47 am, July 12, 2020
linux
tar.gz to compress a directory in linux and then decompress it
...

a pretty common way to zip up contents in a directory into one (or technically two) archive(s). Add to tar.gz This will add the directory and all sub directories into the archive called the-archiv..

2:41 am, May 26, 2020
linux
Find Disk Space Usage using DU
...

The easiest way to check the space used in a directory in linux is this command: du -h This will do the current directory and all its sub directories. if you want to see a specific one type this d..

11:30 pm, April 28, 2020
linux
how to unzip in linux
...

How to easily unzip in linux sudo apt install unzip unzip myzip.zip done.

11:51 pm, December 5, 2019
Welcome

This is my test area for webdev. I keep a collection of code snippits here, mostly for my reference. Also if i find a good site, i usually add it here.

❤👩‍💻🕹

Random Quote
For a long time it had seemed to me that life was about to begin - real life. But there was always some obstacle in the way, something to be gotten through first, some unfinished business, time still to be served, or a debt to be paid. Then life would begin. At last it dawned on me that these obstacles were my life.
Alfred D. Souza