diff options
| author | Dante Catalfamo | 2020-06-17 23:10:02 -0400 | 
|---|---|---|
| committer | Dante Catalfamo | 2020-06-17 23:10:02 -0400 | 
| commit | fa3e9ed8f665cbec794d03d6427911527fe91e4e (patch) | |
| tree | 9c7172fa771e3d89740b542203485c3d239e3421 /content/posts/how-this-blog-works | |
| parent | 97913c29d79777c35bde6f721b6d513ca913c699 (diff) | |
| download | blog-fa3e9ed8f665cbec794d03d6427911527fe91e4e.tar.gz blog-fa3e9ed8f665cbec794d03d6427911527fe91e4e.tar.bz2 blog-fa3e9ed8f665cbec794d03d6427911527fe91e4e.zip | |
More work on blog setup post
Diffstat (limited to 'content/posts/how-this-blog-works')
| -rw-r--r-- | content/posts/how-this-blog-works/index.org | 49 | 
1 files changed, 47 insertions, 2 deletions
| diff --git a/content/posts/how-this-blog-works/index.org b/content/posts/how-this-blog-works/index.org index fcf73ba..0f97fd6 100644 --- a/content/posts/how-this-blog-works/index.org +++ b/content/posts/how-this-blog-works/index.org @@ -56,7 +56,52 @@ through how I run by blog.    org-mode markup is a bit of a second class citizen in the hugo world,    it's pretty easy to figure out. +* Prerequisites +  The only thing that's required on the host server is =git=, although +  you could even get away without that if you chose to host your git +  repository elsewhere, like on github. + +  #+BEGIN_SRC shell +  pkg_add git +  #+END_SRC +  * Version Control -  I wanted to try to keep things as simple as possible for this, while -  remaining private. +  I wanted to try to keep things as simple as possible for this. The +  "origin" for the blog is simply a bare git repository in the =blog= +  user's home directory. This blog user was also made the owner of the +  blog document root directory. + +** Setting up the blog user +   First I set up the blog user +   #+BEGIN_SRC shell +   useradd -m blog +   #+END_SRC + +   I then placed my public SSH key in its =authorized_keys= file + +   #+BEGIN_SRC shell +   mkdir -m 700 /home/blog/.ssh +   cp /root/.ssh/authorized_keys /home/blog/.ssh/ +   chown -R blog:blog /home/blog +   #+END_SRC + +   I then logged in as the blog user and initialize the bare git +   repository. + +   #+BEGIN_SRC shell +   su blog +   cd        # cd with no arguments goes to home directory +   git init --bare blog.git +   #+END_SRC + +** Cloning the repository + +   Cloning the repository onto my local machine is very easy at this +   point. As long as my private keys are in the =blog= user's +   =authorized_keys=, git will take care of the rest. + +   #+BEGIN_SRC shell +   # on my local machine +   git clone blog@lambda.cx:blog.git +   #+END_SRC | 
