Mar 14

To update an image in Google Slides via a URL every day, you can use Google Apps Script. Here’s a step-by-step guide on how to do this:

  1. Open the Google Slides presentation where you’ve inserted the image via URL.
  2. Click on Tools > Script editor. This will open a new tab with the Google Apps Script editor.
  3. In the script editor, paste the following code:
    function updateImage() {
    var slide = SlidesApp.getActivePresentation().getSlides()[0]; // Change the slide index if needed
    var imageUrl = “INSERT_IMAGE_URL_HERE”; // Replace with your image URL
    var image = slide.getImages()[0]; // Change the image index if needed
    image.replace(imageUrl);
    }
  1. Replace “INSERT_IMAGE_URL_HERE” in the code with the URL of the image you want to update.
  2. Save the script with a name (e.g. “Update Image Script”).
  3. Click on the clock icon in the script editor toolbar to open the Triggers dialog.
  4. Click on the “Add Trigger” button.
  5. In the “Run” dropdown, select the name of your function (“updateImage”).
  6. In the “Select event type” dropdown, select “Time-driven.”
  7. Set the time interval you want the image to be updated (e.g. every day at 9:00 AM).
  8. Click on the “Save” button to create the trigger.

That’s it! Now the script will run every day at the specified time and update the image in the first slide of your Google Slides presentation with the new URL you’ve provided.

Share
Nov 09

Followed Guide: https://snipe-it.readme.io/docs/docker

Commands to create SQL and Snipe-It Containers (docker ps – to list containers)

Create your env.txt file and make a note of the full path to it on the machine

Create SQL Container:

docker run –name snipe-mysql –env-file=my_env_file –mount source=snipesql-vol,target=/var/lib/mysql -d -P mysql:5.6

 

Create Snipe-IT container (without SSL) 

docker run -d -p 80:80 –name=”snipeit” –link snipe-mysql:mysql –env-file=my_env_file –mount source=snipe-vol,dst=/var/lib/snipeit snipe/snipe-it:latest

 

Create Snipe-IT container (with SSL)

docker run -d -p 80:80 -p 443:443 –name=”snipeit” –link snipe-mysql:mysql –mount source=snipe-vol,dst=/var/lib/snipeit –env-file=my_env_file snipe/snipe-it

 

Copy the SSL certificate (if using SSL) 

docker cp snipeit-ssl.crt snipeit:/var/lib/snipeit/ssl/snipeit-ssl.crt

docker cp snipeit-ssl.key snipeit:/var/lib/snipeit/ssl/snipeit-ssl.key

 

Run the docker in command line to get APP_KEY

docker run –rm snipe/snipe-it

 

Output will show (actual key will be different than this example):

Please re-run this container with an environment variable $APP_KEY

An example APP_KEY you could use is: 

base64:D5sdfs-zhFSVA3VwuoZoQ21cwBtJv/RGiqOcZ7BUvI=

 

Add the resulting APP_KEY to the env.txt file and generate the container again

Restore the backup file from the previous installation

scp <backupfile.zip> <username>@<hostname>:<destination path>

Copy the Backup to :/var/www/html/storage/app/backups/

docker cp backupfile.zip snipeit:/var/www/html/storage/app/backups/backupfile.zip

 

Copy the Public and Storage files from the previous installation

docker cp /path/to/storage/private_uploads-folder snipeit:/var/lib/snipeit/data

docker cp /path/to/public/uploads-folder snipeit:/var/lib/snipeit/data/

 

Restore the DB in the GUI

You will get a 500 error, just go back in the browser and login again

Share
Apr 10

Every time my display went to sleep, my audio output changed to HDMI (from the line out that I wanted).  After many scripts and temporary fixes, this is how I ended up fixing it.

Open Terminal and run this command: Sudo apt install pavucontrol

Then launch the newly installed PulseAudio Volume Control.  Scroll Right until you get to the Configuration tab.  Set the profile for the appropriate audio device and set the others to “Off”.

Share
Sep 14

This happened when my AD account was deleted and then re-established using the same username.

 

  1. Login to the affected profile
  2. Run Terminal
    1. run “id -u” to get the new user id
    2. run “id -g” to get the new group id
    3. run “sudo chown -R <the userid found in sub-step 1 above>:<the groupid found in sub-step 1 above> /Users/<username>
    4. run “sudo chown -R <the userid found in sub-step 1 above>:<the groupid found in sub-step 1 above> ~/Library
  3. Reboot
Share
Feb 15

This problem always seems to pop up when there is a power outage or I am installing an new HP printer.  I believe it is trying to load the driver/software usb disk, which is not formatted for Mac.  Neither un-pugging/plugging the USB nor turning the printer on/off worked.  The solution is to unplug the usb, then turn the printer on and wait for it to fully turn on.  So both the computer and the printer are fully on.  Then plug the USB in.  Presto!

Share
Mar 06

Trying to mount a windows share into Ubuntu 16.04 LTS.  I could run the following command just fine:

sudo mount -t cifs -o domain=workgroupname,username=myname,password=mypassword //192.168.1.15/music /media/music

But of course would lose the map on reboot.  So install “sudo apt-get install cifs-utils” and then Everytime I tried to add to fstab and “sudo mount -a” I would get the mount error(13) permission denied.

What fixed it was changing the sec on my command to “ntlmsspi”.  Hope this helps someone else.  So my command in fstab (/etc/fstab) is

//192.168.1.15/music /media/music cifs username=myname,domain=workgroupname,password=mypassword,
iocharset=utf8,sec=ntlmsspi 0 0

Now that you have this working you need to create a .smbcredentials file in the /root directory to contain and hide my credentials,

Enter your Windows username and password in the file:

username=msusername
password=mspassword
domain=workgroupordomain

“sudo chmod 700” that file.  and change the fstab line command to :

//192.168.1.15/music /media/music cifs credentials=/root/.smbcredentials,iocharset=utf8,sec=ntlmsspi 0 0


Share
Jan 18

I won’t get into the security implications of doing this, but just the 2 methods I have found to get it done.  My use case was a simple single digital sign that no one had physical access to, and popped this up on every scheduled or unscheduled reboot.

  1. If you don’t mind entering a password on boot, then go to User Accounts and set “automatic login” to off.
  2. If you want it to auto login and still not ask for the login keyring (again forgoing the security lecture), go into your “Startup Programs” and uncheck the Keyrings from starting.

 

Share
Jun 09
  1. Boot with Knoppix live disk or usb
  2. Open a terminal window in Knoppix
  3. Type “sudo sfdisk -l” to see what your disk (that you want to wipe) is mounted as (example – sda1)
  4. Type “sudo shred -vfz -n 100 /dev/sda1” – IMPORTANT – Substitute the disk name learned from above command.  Note that the 100 is the number of passes (and can be changed)
Share
Apr 14

How I use unblock-us on Roku and/or opendns with my Comcast gateway (or your own with Comcast firmware).

The pain of using a Comcast modem and trying to use unblockus or opendns is that Comcast will not allow the Gateway’s DNS to be changed.

Explanation:

Most solutions that is have seen involve putting your gateway in full bridge mode and using your own router and Wifi. I really didn’t like this solution as that is really doubling up on hardware ( not to mention the inconvenience of resetting my router rules and wifi password on all devices).

My solution is achieved through DHCP.  The DNS is set through the DHCP options. So we will set up our own DHCP server.  But there is another problem. The Comcast gateway won’t let us turn off DHCP!  So we have to change it so that it is only giving out one IP address.  Whatever computer gets that address will not have the correct DNS settings!!!  So make sure the correct computer gets the first (non-correct DNS) IP address by turning all other devices off while setting this up)

Solution:

1) (If you have a dedicated computer that is always on) Set up a DHCP server on your dedicated computer with a Static IP.  I have one always on for Plex and PlayOn so that is the computer I set it up on.  Set up a DHCP scope starting with a high ip address (like 100) and with your desired DNS settings. Stop the DHCP service.  Go to step 3

2) (If you do NOT have a dedicated computer that is always on)Get a small device that has DHCP Server capabilities.  I got a TP-Link TL-WR710N for ~$22 on Amazon.  Set up a DHCP scope starting with a high ip address (like 100) and with your desired DNS settings.  Stop the DHCP and/or turn off the TP-Link.  (Here is my TP-Link Config for Unblock-us, username and password is Admin/unblockus15, and must be on Firmware 140922, and disable wireless in wireless settings on the TP-Link, ip of TP-Link will be 10.0.0.99)

3) After you have your DHCP server up and running log into your Comcast Gateway. Go to Connection -> Local IP Configuration.  And change your Beginning and Ending IP address to the same IP.  Set the DHCP Lease Time to forever.

Comcast-DHCP

4) Turn the device/computer on that you don’t care gets the wrong DNS.  it will get the IP you set above.

5) Start your DNS server (on the computer or the dedicated TP-Link type device).

6) Now you should be able to turn your devices back on and they should get the New IP and DNS!

 

Share
Jan 22

HandBrake can through error messages and give you no options (blank) in the Title drop-down because it cannot get past the Content Scramble System (CSS).  Or the resulting video is all garbled.

The best solution I have found is to install XBMC somewhere (doesn’t have to be on the same machine) and copy the libdvdcss-2.dll file out of the XBMC\system\players\dvdplayer folder and into the Handbrake installation folder.

Update: Easiest to just copy the libdvdcss-2.dll from here: http://download.videolan.org/pub/libdvdcss/1.2.11/win64/libdvdcss-2.dll 
Rename it to libdvdcss.dll and copy it to the HandBrake installation folder.

That seems to allow HandBrake to read and rip the disk properly.

Share