└── README.md /README.md: -------------------------------------------------------------------------------- 1 | # FreeLinuxVPS 2 | Get Free Linux VPS With GPU + 12 GB Ram ! With Colab! This Server will working 12 hours If you have Colab Pro Its will Working More Times ! 3 | 4 | **INFO** 5 | 6 | RAM : 12 GB 7 | GPU : YES 8 | GAME AND DEVELOPING: YES 9 | UNLIMITED TIME : NO 10 | DURATION: 12 HOURS (IF YOU HAVE COLAB PRO IS MORE) 11 | Always Access ? : YES 12 | 13 | **THIS COLAB MADE BY KKBv520** 14 | 15 | Good Luck 👍 16 | 17 | **Please Follow me On Github AND Give Star To This repository Thanks!** 18 | 19 | **IF OUR VERSION IS NOT WORKING READ THIS** 20 | 21 | **SETP 1** - Copy This Into Colab 22 | ` ` `!sudo apt update 23 | !sudo apt install libcairo2-dev ffmpeg texlive texlive-latex-extra texlive-fonts-extra texlive-latex-recommended texlive-science tipa libpango1.0-dev 24 | !pip install manim 25 | !pip install IPython --upgrade` ` ` 26 | **SETP 2** - After Copying this make new 27 | Not book In colab Then Make New code Also 28 | Change Runtime TO GPU 29 | **SETP 2** - Copy This Into Colab 30 | ` ` `from manim import *` ` ` 31 | **SETP 3** - Copy this into Colab ( If You want GPU Also You Need Change Runtime To GPU) 32 | ` ` `#@title **GPU T4 INSTALLING** 33 | gpu_info = ! nvidia-smi 34 | gpu_info = '\n'.join(gpu_info) 35 | if gpu_info.find('V100-PCIE...') >=0: 36 | print(gpu_info) 37 | exit() 38 | else : 39 | print(gpu_info)` ` ` 40 | **SETP 4** - Copy This Into Colab 41 | ` ` `#@title **STEP 4 CREATE USER** 42 | 43 | import os 44 | 45 | username = "user" #@param {type:"string"} 46 | password = "root" #@param {type:"string"} 47 | 48 | print("Creating User and Setting it up") 49 | 50 | # Creation of user 51 | os.system(f"useradd -m {username}") 52 | 53 | # Add user to sudo group 54 | os.system(f"adduser {username} sudo") 55 | 56 | # Set password of user to 'root' 57 | os.system(f"echo '{username}:{password}' | sudo chpasswd") 58 | 59 | # Change default shell from sh to bash 60 | os.system("sed -i 's/\/bin\/sh/\/bin\/bash/g' /etc/passwd") 61 | 62 | print("User Created and Configured")` ` ` 63 | **SETP 5** - Copy into colab 64 | ` ` `#@title **INSTALL YOUR VPS BY KKB** 65 | #@markdown It takes 4-5 minutes for installation 66 | 67 | import os 68 | import subprocess 69 | 70 | #@markdown Visit http://remotedesktop.google.com/headless and Copy the command after authentication 71 | 72 | CRP = "" #@param {type:"string"} 73 | 74 | #@markdown Enter a pin more or equal to 6 digits 75 | Pin = 123456 #@param {type: "integer"} 76 | 77 | 78 | class CRD: 79 | def __init__(self): 80 | os.system("apt update") 81 | self.installCRD() 82 | self.installDesktopEnvironment() 83 | self.installGoogleChorme() 84 | self.finish() 85 | 86 | @staticmethod 87 | def installCRD(): 88 | print("Installing Chrome Remote Desktop") 89 | subprocess.run(['wget', 'https://dl.google.com/linux/direct/chrome-remote-desktop_current_amd64.deb'], stdout=subprocess.PIPE) 90 | subprocess.run(['dpkg', '--install', 'chrome-remote-desktop_current_amd64.deb'], stdout=subprocess.PIPE) 91 | subprocess.run(['apt', 'install', '--assume-yes', '--fix-broken'], stdout=subprocess.PIPE) 92 | 93 | @staticmethod 94 | def installDesktopEnvironment(): 95 | print("Installing Desktop Environment") 96 | os.system("export DEBIAN_FRONTEND=noninteractive") 97 | os.system("apt install --assume-yes xfce4 desktop-base xfce4-terminal") 98 | os.system("bash -c 'echo \"exec /etc/X11/Xsession /usr/bin/xfce4-session\" > /etc/chrome-remote-desktop-session'") 99 | os.system("apt remove --assume-yes gnome-terminal") 100 | os.system("apt install --assume-yes xscreensaver") 101 | os.system("systemctl disable lightdm.service") 102 | 103 | @staticmethod 104 | def installGoogleChorme(): 105 | print("Installing Google Chrome") 106 | subprocess.run(["wget", "https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb"], stdout=subprocess.PIPE) 107 | subprocess.run(["dpkg", "--install", "google-chrome-stable_current_amd64.deb"], stdout=subprocess.PIPE) 108 | subprocess.run(['apt', 'install', '--assume-yes', '--fix-broken'], stdout=subprocess.PIPE) 109 | 110 | @staticmethod 111 | def finish(): 112 | print("Finalizing") 113 | os.system(f"adduser {username} chrome-remote-desktop") 114 | command = f"{CRP} --pin={Pin}" 115 | os.system(f"su - {username} -c '{command}'") 116 | os.system("service chrome-remote-desktop start") 117 | print("Finished Succesfully") 118 | 119 | 120 | try: 121 | if username: 122 | if CRP == "": 123 | print("Please enter authcode from the given link") 124 | elif len(str(Pin)) < 6: 125 | print("Enter a pin more or equal to 6 digits") 126 | else: 127 | CRD() 128 | except NameError as e: 129 | print("username variable not found") 130 | print("Create a User First")` ` ` 131 | SETP 6 - AUTO ALIVE 132 | #@title **MAKE ALIVE VPS 24 HOURS** 133 | 134 | alive = False #@param {type:'boolean'} 135 | 136 | ! sleep 999999 137 | 138 | 139 | 140 | **YOU CAN DOWNLOAD OUR CODE IN GITHUB** 141 | --------------------------------------------------------------------------------