Skip to content

Instantly share code, notes, and snippets.

View willianfalbo's full-sized avatar
🎧
Coding for fun!

Willian Falbo willianfalbo

🎧
Coding for fun!
View GitHub Profile
@mobilemind
mobilemind / git-tag-delete-local-and-remote.sh
Last active November 2, 2024 08:30
how to delete a git tag locally and remote
# delete local tag '12345'
git tag -d 12345
# delete remote tag '12345' (eg, GitHub version too)
git push origin :refs/tags/12345
# alternative approach
git push --delete origin tagName
git tag -d tagName

How to add an image to a gist

  1. Create a gist if you haven't already.
  2. Clone your gist:
    # make sure to replace `<hash>` with your gist's hash
    git clone https://gist.github.com/<hash>.git # with https
    git clone [email protected]:<hash>.git     # or with ssh
@mystygage
mystygage / docker-compose.yml
Created March 6, 2017 21:02
Microsoft SQL Server in Docker with data volume
version: '3'
services:
mssql-server-linux:
image: microsoft/mssql-server-linux:latest
volumes:
- mssql-server-linux-data:/var/opt/mssql/data
environment:
- ACCEPT_EULA=Y
- SA_PASSWORD=${SQLSERVER_SA_PASSWORD:-yourStrong(!)Password}
@willianfalbo
willianfalbo / README.md
Last active July 31, 2020 18:11
Enable Virtualization in Hyper-V Virtual Machine (VM)

Run Hyper-V in a Virtual Machine with Nested Virtualization

  1. Turn Off your virtual machine and run the command on the physical Hyper-V host:

Set-VMProcessor -VMName <VMName> -ExposeVirtualizationExtensions $true

  1. Start the virtual machine.

Reference: Run Hyper-V in a Virtual Machine with Nested Virtualization

@willianfalbo
willianfalbo / README.md
Last active April 2, 2022 13:09
Enable Sound Device on Ubuntu 18.04 using Hyper-V Virtual Machine (VM)

xRDP – How to redirect Sound on Ubuntu 18.04

Please follow this tutorial link

Short version is below in case link goes dead.

apt install xrdp-pulseaudio-installer
xrdp-build-pulse-modules
sudo apt-get install xrdp-pulseaudio-installer -y
@willianfalbo
willianfalbo / README.md
Created June 5, 2020 20:55
Enable Enhanced Session Mode in Hyper-V Virtual Machine (VM)

How to enable enhanced session mode in Hyper-V Virtual Machine (VM)

  1. Turn Off your virtual machine and run the command on the physical Hyper-V host:

Set-VM -VMName "Your VM Name" -EnhancedSessionTransportType HvSocket

  1. Start the virtual machine.
@willianfalbo
willianfalbo / README.md
Last active April 18, 2024 13:22
Expanding disk inside Hyper-V using Linux Virtual Machine (Ubuntu)

Expanding disk inside Hyper-V using Linux Virtual Machine (Ubuntu)

  1. Turn off your virtual machine

  2. Go to Settings > SCSI Controller > Hard Drive. In the Media section, edit the Virtual Hard Disk and expand to desired space

  3. Start the virtual machine and connect to it

  4. Install the GParted by running the command sudo apt install gparted

@willianfalbo
willianfalbo / README.md
Last active September 24, 2024 06:36
Install Zsh, Oh-My-Zsh, Fonts-Powerline & Plugins (Ubuntu 18.04+)

Install Zsh, Oh-My-Zsh, Fonts-Powerline & Plugins (Ubuntu 18.04+, MacOS)

Introduction

After following these steps, your terminal will look like:

1. Install Zsh

Zsh is a shell designed for interactive use, although it is also a powerful scripting language.

@willianfalbo
willianfalbo / README.md
Last active October 8, 2020 18:54
How to get a mongo shell running into the docker container

How to get a mongo shell running into the docker container

We can run the interactive shell by running the following command:

docker container exec -it MyContainerName bash

Note: From this command, you will be able to get a bash shell running into the cointainer.

Then, we must get the mongo shell as admin. Otherwise, you will not be able to see the databases and collections.

Run mongo -u "USERNAME" -p "PASSWORD" HOSTIP --authenticationDatabase "admin"