Top N things you should do after installing or upgrading to your new Fedora 36 workstation.
- Method (a): from
Settings
->About
, changeDevice Name
. - Method (b): from terminal, run (change <newhostname> to your liking):
sudo hostnamectl set-hostname <newhostname>
- Go to
Settings
->Devices
->Mouse & Touchpad
to enable touchpad scrolling and taps. - Go to
Settings
->Devices
->Keyboard Shortcuts
to add shortcut for Terminal (Command:gnome-terminal
),Switch windows
,Switch applications
,Hide all normal windows
, etc.
- Go to
Settings
->Displays
to adjust your monitors and resolution settings.
- Fedora 36 comes with
Text-Editor
as the default editor. - If you are a
vim
user, install vim:sudo dnf install vim
- Create file
~/.vimrc
and add following contentsyntax on set shiftwidth=4 softtabstop=4 expandtab set autoindent
- You can customize vim to suit your taste. Examples.
- Edit
/etc/dnf/dnf.conf
and add the following lines at the endfastestmirror=true deltarpm=true
- Install DNF plugins core (should be installed already):
sudo dnf install -y dnf-plugins-core
- Run
sudo dnf -y update sudo dnf -y upgrade
Software
->Software Repositories
->Third Party Repositories
->Enable All
- From the list below, enable required repositories such as google-chrome, nvidia-drivers, steam, etc.
- Free
sudo rpm -Uvh https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm
- Non-free
sudo rpm -Uvh https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
- Install Additional Fonts
sudo dnf install curl cabextract xorg-x11-font-utils fontconfig sudo rpm -i https://downloads.sourceforge.net/project/mscorefonts2/rpms/msttcore-fonts-installer-2.6-1.noarch.rpm
- Open
Software
, Go toUpdates
tab and hit the refresh button. - Install all updates (if any). This may take a few minutes to several hours.
- Alternatively, run
sudo dnf -y update
. - Reboot your system once the process is finished.
- Note: Driver installation is a tricky process and many things can go wrong, proceed with caution.
- Nvidia driver installation guide.
- For AMD GPUs: Open source
amdgpu
driver is already included. - Reboot your system after you have made changes to driver softwares.
- After enabling
google-chrome
package fromThird Party Repositories
, search and install fromSoftware
- Start Chrome from Application Dashboard to update settings, connect google account, enable syncing etc.
- Install VLC Player:
sudo dnf install vlc
- VLC comes in with most common codecs you will need. For additional codecs, open
Software
and searchcodecs
. Install various GStreamer codecs from search results.
- Spotify for Linux is still experimental. Visit official linux distribution page.
- Install using snap:
sudo snap install spotify
- Hide the annoying
snap
directory from your ~ home:
echo "snap" >> .hidden
Comes with Git 2.31+
- Download git-prompts script for command prompt information
wget https://raw.githubusercontent.com/git/git/master/contrib/completion/git-prompt.sh -O .gitprompt chmod 755 .gitprompt
- Download git-completion to autocomplete git commands
wget https://raw.githubusercontent.com/git/git/master/contrib/completion/git-completion.bash -O .gitcompletion chmod 755 .gitcompletion
- Add the following to your
~/.bashrc
file:# git plugins . ~/.gitcompletion . ~/.gitprompt export GIT_PS1_SHOWDIRTYSTATE=1 export PS1='[\u@\h \W]$(__git_ps1 " (%s)")\$ '
- Source your
~/.bashrc
file:source ~/.bashrc
- Update your global config
git config --global user.name "your name" git config --global user.email [email protected] git config --global core.editor vim
- Install:
sudo dnf install -y openssh-server
- Start service at boot:
sudo systemctl enable sshd.service
- Start service:
sudo systemctl start sshd.service
- To test, run:
ssh localhost -l <username>
- (Optional) Change default port:
- Open sshd_config:
sudo vi /etc/ssh/sshd_config
- Find a line:
Port 22
(or#Port 22
) - Change it to some other port number (choose port number between 1024 and 65535):
Port 2222
(make sure to remove commenting#
). - Save the file.
- Update iptables and firewall to allow traffic:
sudo /sbin/iptables -A INPUT -m state --state NEW -m tcp -p tcp --dport 2222 -j ACCEPT sudo firewall-cmd --permanent --zone=public --add-port=2222/tcp sudo firewall-cmd --reload
- Restart sshd service:
sudo systemctl restart sshd.service
- Verify that your new port is open:
netstat -tulpn | grep 2222
- Open sshd_config:
- Run
ssh-keygen
and answer the prompts. - Verify you have the files:
ls ~/.ssh
- Start ssh-agent:
eval `ssh-agent`
- Add private key to ssh-agent:
ssh-add ~/.ssh/id_rsa
- You can now use the content of
~/.ssh/id_rsa.pub
as your public key. - For example, add the content of
~/.ssh/id_rsa.pub
as your bitbucket.org or github.com ssh key. - Note: Fedora33+ drropped SHA1 support. You have to update configurations for legacy hosts such as bitbucket.
- Create a file
~/.ssh/config
with following content:Host bitbucket.org PubkeyAcceptedKeyTypes +ssh-rsa
- Change permission:
chmod 600 ~/.ssh/config
- Create a file
- To verify:
ssh -T [email protected]
or,ssh -T [email protected]
- GPG is often used for signing your release artifacts, commits for GitHub etc. Follow these instructions
- Generating a new GPG key
- Adding a new GPG key to your GitHub account
- Telling Git about your signing key
- Run following commands
sudo rpm --import https://packages.microsoft.com/keys/microsoft.asc sudo sh -c 'echo -e "[code]\nname=Visual Studio Code\nbaseurl=https://packages.microsoft.com/yumrepos/vscode\nenabled=1\ngpgcheck=1\ngpgkey=https://packages.microsoft.com/keys/microsoft.asc" > /etc/yum.repos.d/vscode.repo' sudo dnf check-update sudo dnf install code
- Download tar.gz archive from Toolbox App page.
- Extract and run JetBrains Toolbox binary executable file by double clicking.
- This should install and run the toolbox. You can install your favorite JetBrains IDEs (PyCharm Community, IntelliJ IDEA Community, Android Studio, etc) from the toolbox, it will keep them updated too.
- You can remove downloaded and extracted files after installation.
You can install Postman via snap. Visit https://snapcraft.io/postman. If you do not like snap, you can manually install Postman using the following steps:
- Download the
.tar.gz
file from https://www.postman.com/downloads/. - Extract the archive file:
sudo tar xvzf Postman-linux-x64-8.10.0.tar.gz -C /opt
- Create symlink:
sudo ln -s /opt/Postman/app/Postman /usr/local/bin/postman
- Open a file
~/.local/share/applications/postman.desktop
and add the following content[Desktop Entry] Name=Postman GenericName=API Client X-GNOME-FullName=Postman API Client Comment=Make and view REST API calls and responses Keywords=api; Exec=/opt/Postman/app/Postman Terminal=false Type=Application Icon=/opt/Postman/app/resources/app/assets/icon.png Categories=Development;Utilities;
- Hide postman directory from your home:
echo "Postman" >> .hidden
- Comes with gcc 11.
- If you use
g++
command, you can installsudo dnf install gcc-g++
- Fedora 36 comes with Python 3.10, follow this for older versions of Python 3.
- Install python headers and static libraries:
sudo dnf install python3-devel
- Update pip:
python -m pip install --user --upgrade pip
- Install python libraries like
cookiecutter
,tox
,pytest
, etc using pip.
- Visit Oracle's site to download and install Oracle's Java SDKs. Be careful about licensing if you are using a later version than Java 8. It is recommanded to use JDK libraries locally to avoid system-wide mess with
update-alternatives
command.
- Download linux archive and run
tar -C /usr/local -xzf go$VERSION.$OS-$ARCH.tar.gz
- Upate
$PATH
variable at the end of your~/.bashrc
file:export PATH=$PATH:/usr/local/go/bin
- Source bashrc file:
source ~/.bashrc
- Use NVM (Node Version Manager) to install and manage multiple version of NodeJS and npm following this guide
- Installation:
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.35.1/install.sh | bash
source ~/.bashrc
orexec bash
- Run
nvm ls-remote
to list down all available node versions - Install your required version using nvm. Example:
nvm install 16.17.1
- Actiate a specific version using nvm. Example:
nvm use 16.17.1
- Install Apache HTTP server following this guide
- Test if the HTTP server is running:
sudo systemctl status httpd
Podman comes with Fedora/CentOS/RHEL systems. Podman should be able to work with your dockerfiles, and in many cases, a more flexible option. Anyway, you can install docker in Fedora 34/35/36. Note: For older versions of Fedora, Docker can only be installed after downgrading to cgroup v1.
- Install the dnf-plugins-core package (which provides the commands to manage your DNF repositories) and set up the repository.
sudo dnf -y install dnf-plugins-core sudo dnf config-manager \ --add-repo \ https://download.docker.com/linux/fedora/docker-ce.repo
- Install the latest version of Docker Engine, containerd, and Docker Compose or go to the next step to install a specific version:
sudo dnf install docker-ce docker-ce-cli containerd.io docker-compose-plugin
- Start docker service and check status
sudo systemctl start docker sudo systemctl status docker
- Add yourself to docker usergroup to access without sudo
sudo usermod -aG docker $(whoami) && newgrp docker
- Update firewall
sudo firewall-cmd --permanent --zone=trusted --add-interface=docker0 && sudo firewall-cmd --reload sudo firewall-cmd --permanent --zone=FedoraWorkstation --add-masquerade
- Verify that Docker Engine is installed correctly by running the hello-world image.
sudo docker run hello-world
Docker Desktop is an easy to use app to track your docker images and maintain image lifecycle.
- Set up repository
sudo dnf -y install dnf-plugins-core sudo dnf config-manager --add-repo https://download.docker.com/linux/fedora/docker-ce.repo
- Download rpm package using wget or from here
wget https://desktop.docker.com/linux/main/amd64/docker-desktop-4.13.0-x86_64.rpm
- Install RPM Package
sudo dnf install -y docker-desktop-4.13.0-x86_64.rpm
- Search Docker Desktop on the Applications menu and open it. This launches the whale menu icon and opens the Docker Dashboard, reporting the status of Docker Desktop. Alternatively, open a terminal and run:
systemctl --user start docker-desktop
Any suggestions? Please feel free to add suggestions in the comments below. Happy software engineering.