Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

IMAP Mail Server (incoming):
User Name: {username}@illinois.edu
Server Name: outlook.office365.com
Server Port: 993
Connection security: SSL/TLS
Authentication method: OAuth2

SMTP Mail Server (outgoing):
User Name: {username}@illinois.edu
Server Name: outlook.office365.com
Server Port: 587
Connection security: STARTTLS
Authentication method: OAuth2

...

# Needed after fresh install of Ubuntu 22.04 : 
sudo apt-get install libgconf-2-4
./install.sh -u $USER -x $HOME/.local/bin/crashplan
# Running as user means the installer cannot increase file system watchers on its own:
echo 'fs.inotify.max_user_watches=1048576' > /etc/sysctl.conf
sudo sysctl -p /etc/sysctl.conf
  

Add an automatic startup script when you login by using the graphical Startup Applications tool or by creating the autostart file on the command line like so:

$ cat ~/.config/autostart/service.sh.desktop 
[Desktop Entry]
Type=Application
Exec=$HOME/.local/bin/crashplan/bin/service.sh start
Hidden=false
NoDisplay=false
X-GNOME-Autostart-enabled=true
Name[en_US]=CrashPlan
Name=CrashPlan
Comment[en_US]=CrashPlan service
Comment=CrashPlan service

Copy the desktop file to your applications folder to enable convenient launch of the desktop app. You may need to restart the desktop after creating this file by pressing ALT+F2 and executing the command "restart".

...

Create a startup application. Make it graphically by launching the Startup Application app or create the shortcut file:

  
cat <<EOF > $HOME/.config/autostart/syncthing.desktop
[Desktop Entry]
Type=Application
Exec=/usr/bin/syncthing -no-browser -home="$HOME/.config/syncthing"
Hidden=false
NoDisplay=false
X-GNOME-Autostart-enabled=true
Name[en_US]=Syncthing
Name=Syncthing
Comment[en_US]=Syncthing launcher
Comment=Syncthing launcher
EOF

...

If you have problems with the audio output and microphone input changing to the dock devices you do not want when you plug in, follow the instructions in this helpful repo.

README.md

  # DellDockAudio
Forces pulseaudio sound device switch via script when docking station detected. Tested on Ubuntu 20.04 only.
## Why? I have a Dell WD19 dock and a Latitude 5580 runing Ubuntu 20.04. When I plug my dock in to my laptop, it switches sound output to the dock's headphone jack rather than the dock's line-out jack. If I change the sound output device in settings, it will work fine until I unplug the dock. It "forgets" my choice when I plug it back in. ## Info needed for this script to work If you have the same issue as I described above, there's some info you'll need in order to customize the included files to work with your hardware. Example output below is cleaned up to only show the relevant needed info... 1. Your Username and UID: ``` echo $USER johnsmith echo $UID 9999 ``` 2. Sound Device names (Set the desired sound devices in the GUI before running this command): ``` pacmd stat Default sink name: alsa_output.usb-Generic_USB_Audio_200901010001-00.HiFi__hw_Dock_1__sink Default source name: alsa_input.usb-Generic_USB_Audio_200901010001-00.HiFi__hw_Dock__source ``` 3. Hardware ID of the docking unit: ``` lsusb Bus 002 Device 005: ID 0bda:0487 Realtek Semiconductor Corp. Dell dock ``` If your dock isn't as easy to find as the example above, run the command with and without the dock plugged in and compare the devices listed to determine the correct device. ## Customizing the rules file In step 3 above, the example device listed has a vendor ID of "0bda", and a product ID of "0487". Use the values of your dock ID and replace these values in the `docksound.rules` file. ## Customizing the script file Edit `docksound.sh` with the info you gathered in steps 1 and 2, replacing the values **within the quotes** of the following variables: ``` SINK_NAME corresponds to "Default sink name" SOURCE_NAME corresponds to "Default source name" USERNAME corresponds to "$USER" USERID corresponds to "$UID" ``` ## Putting the files in the right place You will need root access to put the files where they need to go. The script will be run as root. You may need to `chmod +x docksound.sh` to make it executable. Place `docksound.rules` in `/etc/udev/rules.d/` Place `docksound.sh` in `/root/`. If you want to put `docksound.sh` somewhere else, you'll have to change the path in `docksound.rules` to point th the right location. ## Misc You can `tail -f /tmp/DockPlugEvent.log` to watch detection happen. When I plug my dock in it gets detected multiple times, which is why the script checks if the desired sound devices are already active before switching. Each detection fires an instance of the script...

docksound.rules

    ATTRS{idVendor}=="0bda", ATTRS{idProduct}=="0487", ACTION=="add", RUN+="/root/docksound.sh"

docksound.sh

#!/bin/bash
# Define Variables
SINK_NAME='alsa_output.usb-Generic_USB_Audio_200901010001-00.HiFi__hw_Dock_1__sink'
SOURCE_NAME='alsa_input.pci-0000_00_1f.3.analog-stereo'
USERNAME=andrew
USERID=1000
PID=$(echo $$)

# Log dock detection
echo "$(date) - PID:$PID Dock detected" >> /tmp/DockPlugEvent.log

# Terminate script if an instance is already running
#echo $PID
ps aux | grep 'docksound.sh' | grep -v -e 'grep' -e "$PID"
if [[ $? -gt 0 ]]
then
echo "$(date) - PID:$PID No other instance detected, proceeding" >> /tmp/DockPlugEvent.log
else
echo "$(date) - PID:$PID Another instance detected, exiting." >> /tmp/DockPlugEvent.log
exit 0
fi

export PULSE_RUNTIME_PATH="/run/user/$USERID/pulse/"

# Wait for things to settle after dock is plugged in
sleep 2

# Check to see if desired sound devices are already set, and EXIT without changing IF TRUE
sudo -u $USERNAME -E pacmd stat | grep $SINK_NAME &&
sudo -u $USERNAME -E pacmd stat | grep $SOURCE_NAME &&
echo "$(date) - PID:$PID Desired Sound device already active, exiting" >> /tmp/DockPlugEvent.log &&
exit 0

# Change sound Source and Sink to the Docking Station sound device if NOT already set
echo "$(date) - PID:$PID Firing Sound device switch" >> /tmp/DockPlugEvent.log
sudo -u $USERNAME -E pacmd set-default-source "$SOURCE_NAME"
sudo -u $USERNAME -E pacmd set-default-sink "$SINK_NAME"
echo "$(date) - PID:$PID Fired Sound device switch" >> /tmp/DockPlugEvent.log

Development environment and apps

...