Setting up *Your Own* Git Server

Поделиться
HTML-код
  • Опубликовано: 16 июн 2020
  • If you want to keep your projects on your own server or website, without using Github or Gitlab or a similar site, it's actually extremely easily. In this video, I set up a git server on my website at git.lukesmith.xyz. It is easy and doesn't really cause any bandwidth strain or other issues. Later, I'll be adding on a GUI html interface called stagit.
    WEBSITE: lukesmith.xyz 🌐❓🔎
    DONATE: lukesmith.xyz/donate 💰😎👌💯
    OR affiliate links to things l use:
    www.epik.com/?affid=we2ro7sa6 Get a cheap and reliable domain name with Epik.
    www.vultr.com/?ref=8384069-6G Get a VPS and host a website or server for anything else.
    brave.com/luk005 Get the Brave browser.
    lbry.tv/$/invite/@Luke View my videos on LBRY.
    www.coinbase.com/join/smith_5to1 Get crypto-rich on Coinbase.
  • НаукаНаука

Комментарии • 264

  • @kednog8739
    @kednog8739 4 года назад +561

    Setting a server? Just like for minecraft

    • @therealjib
      @therealjib 4 года назад +83

      It’s like he’s playing minecraft but in real life!

    • @Jupiter__001_
      @Jupiter__001_ 4 года назад +1

      @@cosmojg looks interesting

    • @logangraham2956
      @logangraham2956 3 года назад

      @@cosmojg minetest is awesome .
      but i do have a small gripe about it .
      wish i could swap the mouse buttons.

    • @noorbasha8725
      @noorbasha8725 2 года назад

      Hi @kednog, can you please help me to find the second part of this tutorial where we can add GUI to see all our PR and comment stuffs, please

    • @wolverine9632
      @wolverine9632 2 года назад +3

      But what's the wecommended amount of deditaded WAM for a server?

  • @Shadepariah
    @Shadepariah 4 года назад +407

    >Github changes master to main
    >Luke sets up own git server
    Coincidence?

    • @SimGunther
      @SimGunther 4 года назад +30

      "Simple search and replace"
      - Jupiter Broadcasting
      Congratulations, we solved racism XD

    • @juliankandlhofer7553
      @juliankandlhofer7553 4 года назад +89

      @@SimGunther the future:
      > congratulations on your mains degree
      > you will compete against a chess grandmain
      > it took years to main the art of kung fu

    • @MrChickenpoulet
      @MrChickenpoulet 4 года назад +46

      @@juliankandlhofer7553 "Do you take the maincard as a payment method ?"

    • @naipeadicto
      @naipeadicto 4 года назад +28

      @@MrChickenpouletmy favourite album is definitely main of puppets

    • @MrChickenpoulet
      @MrChickenpoulet 4 года назад +27

      @@MrCrashDavi "my favourite character of Halo is main chief"

  • @sebastianbitzer4232
    @sebastianbitzer4232 4 года назад +216

    > using the newbie interactive perl script "adduser" instead of the standard unix binary "useradd"
    absolutely disgusting

    • @richardlighthouse5328
      @richardlighthouse5328 4 года назад +2

      Luke is part of Bloated Software Master Race. Disgusting!

    • @____-gy5mq
      @____-gy5mq 4 года назад +1

      Isn't it the other way around?

    • @shirgar4390
      @shirgar4390 4 года назад +1

      “useradd” is actually the native binary, and “adduser” is the Perl wrapper. There’s no reason not to use “adduser”, the functionality is the exact same between the two, and “adduser” tends to be easier to use. Less mental bloat.

    • @1Yooter
      @1Yooter 4 года назад

      Heresy, I say!

    • @gestaltengine6369
      @gestaltengine6369 4 года назад +7

      Disgusting, absolutely

  • @douwehuysmans5959
    @douwehuysmans5959 4 года назад +106

    >Is logged in as root
    >uses sudo

    • @Shvmadogg
      @Shvmadogg 4 года назад +9

      old habit when using Linux as your desktop. it happens to me a lot on servers (and this is my job)

    • @glowiever
      @glowiever 4 года назад +9

      when you need that extra firmness

    • @pepijnkrijnsen4
      @pepijnkrijnsen4 3 года назад +4

      Extra super!

  • @doom-and-gloom
    @doom-and-gloom 4 года назад +54

    watching you instead of preparing for exam

    • @collinmoran4817
      @collinmoran4817 4 года назад +21

      Setting a bad example for the zoomers smh

    • @kot3405
      @kot3405 4 года назад +1

      mmm mmm angielski jutro

  • @marc-alexandrelaroche6632
    @marc-alexandrelaroche6632 4 года назад +76

    Show us how to setup a Minecraft server.

    • @sesar_5467
      @sesar_5467 4 года назад +1

      Here is a good guide. Used it myself. wiki.archlinux.org/index.php/Minecraft#Server

    • @Harry1life
      @Harry1life 4 года назад +1

      try opensource alternative - minetest. There are plenty mods for it as gregtech, ic2 etc (similar/same mods as for minecraft).

    • @antong1036
      @antong1036 4 года назад +2

      java -jar server.jar

  • @_b001
    @_b001 4 года назад +24

    This channel has the best thumbnails

  • @jarilo8639
    @jarilo8639 4 года назад +147

    only master branches? Didn't you hear, they are called main branches now.

    • @richardlighthouse5328
      @richardlighthouse5328 4 года назад +45

      I don't understand why GitHub is changing the "main" branch from master to main to avoid slavery. WTF? If you follow that logic, it technically makes you racist. So "master copy" is now racist too? This is solution looking for problems.

    • @Shorthouse061
      @Shorthouse061 4 года назад +72

      @@richardlighthouse5328 leftism is all about illogical, surface level wokeness. Skin colour emojis are the best example of this. If they really wanted to embrace "content of your character" then we would all be using generic yellow emojis, but now you are constantly reminded of people's race whenever they use these things. Tools like slack that store your preference of skin colour emoji are literally asking you to specify your race and then storing it in a giant database lmao.

    • @MrChickenpoulet
      @MrChickenpoulet 4 года назад +6

      hmmm so this is real ? got the feeling this is a trap, if you say it's unnecessary you become a hardcore racist and get blocked by "good people" from twitter and so on, can't argue with this people :(
      This really does not seem useful, how can anyone be offended by the "master" branch wth.
      So let's go now, delete the white house, the master diploma, the mastercard, the game mastermind and so on, I think this terms are racists !

    • @Kevzz2srs
      @Kevzz2srs 4 года назад +3

      @MΛX not for long

    • @TheClazziquai
      @TheClazziquai 4 года назад +10

      Haha, like those ppl who make an argument 'blacklist' should be called 'denylist' because 'blacklist' is racist without them realizing they are racist for making this connection to begin with.

  • @clockworkpc
    @clockworkpc 3 года назад +5

    Superb video, I followed along and had my very own dotfiles backed up to my private server in no time.
    Truly, thou art a scholar and a gentleman.

  • @CanaldoKhal
    @CanaldoKhal Год назад +3

    WoW this is incredibly simple and easy, and you did great guiding that!

  • @queseyopa
    @queseyopa 4 года назад

    < 20 Mins videos, interesting and straight to the point material, no bullshit. I like your new format boy. you have skills.
    salute from Argentina

  • @milesrout
    @milesrout 4 года назад +24

    Luke moving to the woods so his slower internet will extend out his videos for more ad revenue

  • @richardlighthouse5328
    @richardlighthouse5328 4 года назад +3

    Can't wait for the next video!

  • @mockingbird3809
    @mockingbird3809 4 года назад +22

    I'm loving "Setting your own servers" series. We need more videos Luke!

    • @noorbasha8725
      @noorbasha8725 2 года назад

      Hai @keyboard Warrior, may i know the second part did you find? can you please help

    • @noorbasha8725
      @noorbasha8725 2 года назад

      Hi keyboard warrior can you please help me to find out the second part of this tutorial where we can see everything in gui ?

  • @anonanon8464
    @anonanon8464 4 года назад +23

    Luke use this CoC:
    1. Write good code;
    2. Don't sue me for any reason.

  • @StanleySisneros
    @StanleySisneros 3 года назад

    Thank you for this. Helped me understand some things I was curious about.

  • @joshmoore6702
    @joshmoore6702 4 года назад +5

    I was just thinking about this the other day. Based Luke reading my thoughts

  • @pavelow36
    @pavelow36 3 года назад

    just what I needed. thank you.

  • @NeerajSharma-oz1mm
    @NeerajSharma-oz1mm Год назад

    You make it sound so easy! wow

  • @hellboy6507
    @hellboy6507 4 года назад +44

    Imagine being a Gitcel.
    True chads write their own version control system with no dependencies.

  • @GavinFreeborn
    @GavinFreeborn 4 года назад +16

    Literally no one:
    Luke: "MY INTERNET IS EXTREMELY SLOW"

  • @corporatemonkey
    @corporatemonkey 3 года назад

    Explained very well. Thank you. I have subscribed.

  • @tonyvitonis
    @tonyvitonis 3 года назад +1

    Excellent stuff. Instant subscribe. Looking forward to your demo on stagit, too.

    • @etutorshop
      @etutorshop Год назад

      I am looking forward to that too.

  • @mophead387
    @mophead387 4 года назад

    More videos like this Luke!

  • @Andrath
    @Andrath 4 года назад +30

    Another recommendation: gitea

    • @bdnugget
      @bdnugget 4 года назад +3

      This. I have one for myself and set up one for the company, takes like 5 minutes to get everything up and running and works great. Also private repos before Github decided they should make it free as well.

    • @randomuser5237
      @randomuser5237 4 года назад

      Emiel Kollof
      That dude uses suckless tools, you think he is going to install bloat like gitea and use a browser like a normie?:D But seriously though for small repositories like dotfiles or other config files which are mostly meant to be shared with other users and not involving a lot of collaborative development, gitea/gogs/gitlab etc, are not necessary and a simple ssh/http based server is enough.

    • @bdnugget
      @bdnugget 3 года назад

      @-- yep, that's why you set up your own gitea instead

  • @ybhall
    @ybhall 4 года назад +14

    If you want something a tad simpler, after you create the git user, you should be able to
    exit back to your local machine
    ssh-copy-id git@server
    enter password
    That should create your .ssh directory and authorized_keys file with your key and all the proper permissions.

  • @AhmedShakil
    @AhmedShakil 2 года назад

    Thank you!

  • @kesnelsamuel
    @kesnelsamuel 3 года назад

    Thank you Sir,, this helped me a lot !!!

  • @waltereikrem
    @waltereikrem 4 года назад +1

    i know the struggle about internet speeds while living in the middle of nowhere. i my self live in the mountains here in norway. about 1.5 km to the closest other human lol. and ive found that using 4g hotspot from my phone, with a unlimited data plan was the cheapest way to get online here. and i actually am up to 1mb/s now from where i was at 300kbs. kinda cool, plus its just one bill for my phone and internet now. totally worth the struggle to live away from all the chaos imo.

  • @bp-ik7lz
    @bp-ik7lz 4 года назад +54

    When are you going to do the "Create meme thumbnails without Photoshop" video

    • @Willwantstobeawesome
      @Willwantstobeawesome 4 года назад +18

      he's already has with gimp and imagemagick :)

    • @Horstlicious
      @Horstlicious 4 года назад +2

      ruclips.net/video/5m8Oaz8XWVI/видео.html

  • @fitzpatrickmathemati
    @fitzpatrickmathemati 4 года назад

    Would love to see a walkthrough on setting up a VPS!

  • @pZq_
    @pZq_ 4 года назад

    This is good stuff!

  • @mikeziri
    @mikeziri 4 года назад +1

    cool.
    you should take a look at the git flow standard.
    it's just naming conventions for branches and dev workflow.
    there are actually scripts that do the git flow for you.

  • @senninscorpion
    @senninscorpion 4 года назад

    A video on technicalities of git bare repositority on managing the dot files would be awesome.

  • @ntong11
    @ntong11 3 года назад

    Thanks for your knownledge

  • @Lunolux
    @Lunolux 2 года назад

    great video, thx,
    i setup my git server, and when i do "git push" it's push to github and to my "raspberrypi" this is crazy, never though this will be that easy to setup

  • @DannyMexen9
    @DannyMexen9 4 года назад +1

    Luke. I did it. I switched to suckless on Arch and learned how to patch.
    And now I can't stop messing with my configs.
    On topic. I have been running my own git server for years. Still an informative video as usual.
    Take care, man.
    I did it!

  • @jacobkoziej
    @jacobkoziej 4 года назад +5

    With such painfully slow internet it might be worth setting up mosh so when you ssh into your server it doesn't feel slow and unresponsive.

  • @tenminutetokyo2643
    @tenminutetokyo2643 Год назад

    Awesome dood.........

  • @durikke2
    @durikke2 27 дней назад

    Thanks for being a good boy before it became a thing. nice video!

  • @user-so8em5lp8h
    @user-so8em5lp8h 4 года назад +1

    Hey man! Thanke you for your videos. In chromium you can find extension "vimium" - it help dont use mouse in browser. I think it save your time ;)

  • @MichaelStJohn-kc1tn
    @MichaelStJohn-kc1tn 2 года назад +5

    Nice video, did you made the second part for it as well? Setting up the Web Interface for the Git Server?

  • @Lunolux
    @Lunolux 2 года назад

    it's "that" simple to install our own git server WOW,
    gonna try that on my raspberry pi, thx

  • @stephenstrange1178
    @stephenstrange1178 2 года назад

    thanks

  • @akemrir
    @akemrir 4 года назад

    Nice video :) It is very simple and clear.
    In next video it will be simple commit/branches reading app? It will have pull-request functionality?

  • @dhdh9933
    @dhdh9933 4 года назад

    been loving this upload rate !!

  • @filaxkun457
    @filaxkun457 4 года назад

    Niice!

  • @mark7824
    @mark7824 4 года назад +4

    Luke try mosh (mobile shell) instead of ssh, it doesn't wait for your server's response every time you type. It's literally made for people living in the woods

  • @angusmacgyver
    @angusmacgyver 4 года назад +1

    You are creating content I can CONSUUME a lot nowadays. You can chown a file for the group by appending the username with a dot. So chown git. makes the FILe owned by git group also.

  • @HeDoesNotRow
    @HeDoesNotRow 4 года назад

    Wouldn't hurt if you went through explaining the DNS records a bit, especially considering your latest video!

  • @johnsmail8653
    @johnsmail8653 4 года назад

    YES

  • @avrumy
    @avrumy 4 года назад +1

    You can set your alias to push `HEAD` instead of `--all`.

  • @liamwynn3269
    @liamwynn3269 3 года назад +3

    Thank you so much for this tutorial! Do you have plans to do one on adding the front end GUI anytime soon?

    • @swindlesmccoop
      @swindlesmccoop 2 года назад +1

      If you want a frontend, Gitea is pretty good. Very similar look and feel to GitHub, and it's extremely easy to set up.

  • @dddonehoo7
    @dddonehoo7 3 года назад +1

    any possibility you could post the second video going through the process for making a web frontend? I have been going through hell with gitweb, teach us senpai

  • @caseydwayne
    @caseydwayne 2 года назад

    (Milton from Office Space:) I was told there would be a part two?

  • @patrickmullan8356
    @patrickmullan8356 4 года назад +1

    The 2nd part on this series, i.e., the part Luke explains how to setup a web frontend, is not yet uploaded, is it?
    At least I cant find it...

  • @keveinkevin4422
    @keveinkevin4422 4 года назад +17

    Is this because github is gonna stop using master terminology?

    • @richardlighthouse5328
      @richardlighthouse5328 4 года назад +5

      I don't understand why GitHub is changing the "main" branch from master to main to avoid slavery. WTF? If you follow that logic, it technically makes you racist. So "master copy" is now racist too? This is solution looking for problems.

    • @keveinkevin4422
      @keveinkevin4422 4 года назад +6

      @@richardlighthouse5328 sacrificing some developer conveinience for a bit of attention from the woke press, amplified by righties. Not worth getting upset about imo

    • @tyrrelldavis9919
      @tyrrelldavis9919 4 года назад +8

      @@keveinkevin4422 fuck Microsoft fuck github

    • @BCDeshiG
      @BCDeshiG 4 года назад

      He had his own git server before which he's setting up again here

    • @wexwexexort
      @wexwexexort 4 года назад

      With their logic, github secretly calls devs who pushes into master as racists.

  • @jongdonglu
    @jongdonglu 4 года назад

    Hey Luke, thanks a lot for this video just did this for my local hp device, i was wondering is there a way i can make a ""Root folder" for all the repositories to automatically push to when i do "git push home master" so i can have '/var/www/git/' as the location at the end of the URL in gitconfig instead of '/var/www/git/project_name.git' or do i really need to use 'git remote add' every time? Thanks again i'm smiling like a maniac now i have a self-hosted repo!
    Edit: Also forgot to mention i REALLY love the idea to put in in /var/www/ as im building my little hp box into an offline backup of sorts, it already has map data, stack exchange, and a few other dumps that i can read offline, along with a a copy of the NHS site and pubmed database for if i need medical information but dont have internet.. a

  • @webwagner
    @webwagner 5 месяцев назад

    hey i am looking for the next video but i can't see it where is it ? And very nice video

  • @noorbasha8725
    @noorbasha8725 2 года назад +2

    Hi Luke Smith, thanks for the wonderful tutorial, I followed the same I am facing one issue. while cloning and pushing it is asking the password of the server. and I am unable to find the second part of this tutorial can you please help on this thanks

  • @slmjkdbtl
    @slmjkdbtl 4 года назад

    0:30 did they use some kind of software to generate the git site? I've seen a lot of people's git site has the exact same layout and styles

  • @danielkrajnik3817
    @danielkrajnik3817 11 месяцев назад

    8:45 Morgan Freeman: but it did take longer than 10 seconds

  • @ricardonunes709
    @ricardonunes709 4 года назад +1

    next...something about lxc/lxd and chroot environment?

  • @ReviveNRepair
    @ReviveNRepair 4 года назад +1

    You totally need keybindings for moving your face around on a grid or something.

  • @skittlesvampir8400
    @skittlesvampir8400 4 года назад

    You uploaded this right after I installled gitea. :(

  • @tyrisnolam
    @tyrisnolam 4 года назад +3

    Hey, I'm not from the USA and we count on fingers differently. I knew English speaking cultures frequently start counting using the index finger and the thumb is the fifth, but is that only true for numbers 1 - 5? I thought it's the same on the left hand for 6-10 but you started counting 6 using your left thumb instead of the left index.
    @8:48 vs 8:53
    anyway, thanks for the video, I'm working on my own independent infrastructure including my own git server

  • @arnoldwolfstein
    @arnoldwolfstein 4 года назад

    Next video Luke: How to set up your NASA base space station.

    • @arnoldwolfstein
      @arnoldwolfstein 4 года назад

      Btw like your own search engine and this video as well.

  • @Gamex996
    @Gamex996 4 года назад

    u can host gitLab, or now GiTea which looks alot like github

  • @nnaaaaaa
    @nnaaaaaa 4 года назад

    cgit is a pretty nice simple http git ui. would recommend.

    • @jacobkoziej
      @jacobkoziej 4 года назад

      Although cgit is nicer than stagit, the only issue with it is that it's a dynamic program while stagit just pumps out static pages.

  • @webbonyoutube
    @webbonyoutube 4 года назад +8

    58 seconds gang

    • @alepharcane99
      @alepharcane99 4 года назад

      Your gf must be proud of you 😉😂

    • @webbonyoutube
      @webbonyoutube 4 года назад

      @@alepharcane99 with a girlcock on her tho 😍😍😍😍😍😍😍

  • @rae6261
    @rae6261 4 года назад

    1k geng

  • @Hypnosing
    @Hypnosing 4 года назад

    You can use gitolite to manage git repositories yourself

  • @YusufBAYLAV
    @YusufBAYLAV 4 года назад

    Luke, when do you plan to make the stagit video?

  • @omarnabeel8383
    @omarnabeel8383 4 года назад +1

    creating files on the server side seems a bit tedious maybe you can write some code to automatically create these files based on the repos name.
    And you could've just installed a gitlab server on your machine for this but I really wanna see how you'll manage it all, best of luck!

  • @con_sci
    @con_sci 4 года назад

    Make sure your main branch is named 'master' :^)

  • @kacperw587
    @kacperw587 4 года назад

    Uhh, your diff for adding Aporcypha to kjv looks funny on your website...

  • @xdevs23
    @xdevs23 4 года назад

    Use mosh instead of ssh, makes it easier

  • @armynyus9123
    @armynyus9123 4 года назад

    I so miss my `hg serve`

  • @JustKatoh
    @JustKatoh 4 года назад

    GitBucket is rather nice, you should take a look at it as it's FOSS

  • @mro2352
    @mro2352 3 года назад +1

    I want to expose the git server online. how do i harden the endpoint so that it uses only ssh protocol is allowed. I cant see anything online on it.

  • @jimdaniels4595
    @jimdaniels4595 4 года назад

    Lmao. I also setup my own Github clone. I ended up using Gogs.

  • @WodenIstWotan
    @WodenIstWotan 4 года назад +2

    where is the git web interface setup video?

  • @nikolailiev3546
    @nikolailiev3546 2 года назад

    any chance you make a video how to make a local git with gitolite administration;

  • @TheToniz4
    @TheToniz4 4 года назад +1

    How can i setup a alias to /var/www/git?

  • @hotscriptgg
    @hotscriptgg 4 года назад

    If you need your own server with web gui use opensource gitea.

  • @PandemicGameplay
    @PandemicGameplay 4 года назад

    You can also just use Docker and setup your own Gitlab....

  • @vishnuk.v8529
    @vishnuk.v8529 3 года назад +3

    No part 2?

  • @ilovecodingWorld
    @ilovecodingWorld 2 года назад

    Sir can we see the code on server side pushed by devolpers??

  • @TheKaruso33
    @TheKaruso33 4 года назад +4

    Do you upload your videos with that internet connection?

    • @sophiatheodores7985
      @sophiatheodores7985 4 года назад +6

      no he puts videos on a thunb drive and drives to australia to upload them

    • @wexwexexort
      @wexwexexort 4 года назад +3

      @@sophiatheodores7985 I've just imagined this, lol.

  • @jamesm5192
    @jamesm5192 4 года назад

    Most of us developers have become accustomed to have a lot more than just Git... And it really is necessary if available. So, if we want self-hosted, then something like GitLab really is necessary. Unfortunately it is quite bloated (in terms of config management)... Their default setup runs chef in Docker! And if you question them about it they come up with all sorts of excuses...

  • @yadunan8613
    @yadunan8613 3 года назад

    can we connect this git server with our own Jenkins ?

  • @twl148
    @twl148 4 года назад +1

    how the hell do you upload every day???

  • @farihamorshed2232
    @farihamorshed2232 Год назад

    Is it possible to create multiple gitolite account in a server ?

  • @KingHerring
    @KingHerring 4 года назад

    :-OO

  • @lenglain8230
    @lenglain8230 3 года назад +1

    What happened to the follow up to this??

  • @marcello4258
    @marcello4258 Год назад

    When is part 2 coming?

  • @dylanbyrnside
    @dylanbyrnside 4 года назад

    Do you use separate vps's for mail, searx, git, etc?

    • @skatcat743
      @skatcat743 4 года назад

      separate servers sounds like bloat and expense

  • @kamshorymt
    @kamshorymt Год назад

    Can Git Server be installed on WIndows 11?

  • @willpaxman5236
    @willpaxman5236 4 года назад +1

    Wheres your forum gone?

  • @LambOfDemyelination
    @LambOfDemyelination 4 года назад

    You can do:
    git remote set-url --push --add origin "git@git.lukesmith.xyz:/var/www/git/dotfiles.git"
    That adds a 'pushurl' to your origin, so 'git push' pushes to the github url and all the 'pushurl's you add.