Skip to main content

Documentation

To help with local development of this docusaurus website, a debian OVA has been prepared. Instructions for it's usage can be found here. The following are instructions on how to utilize the debian guest.

Debian Guest OVA File

The OVA standard file for the debian guest with docusaurus can be downloaded from https://is3.cloudhost.id/francis/sp231/ova-docusaurus-standarized-v.1.0.0.ova

OVA download

The OVA is quite large (+-1.57GiB), and my cloud provider is cheap, so maybe try to use multi-connection downloads such as using aria2c or Free Download Manager.

How to use the OVA

  1. Login using
username: cbkadal
password: cbkadal
  1. change the directory to code/os-documentation
cd code/os-documentation
  1. Run the necessary preperation commands
yarn build
yarn serve

Other OVA notes

Internal portExternal Port
226022
30005001
40005000

How to setup the debian guest with Docusaurus

A script is included in the OVA called prepare-nodejs.sh. Running it should be sufficient to setup everything we need to setup all NodeJS and other system packages needed.

export DEBS1="apt-file aptitude autoconf automake bc bison build-essential cowsay curl dateutils dos2unix fail2ban flex gawk gettext git git-flow gnupg gnupg-agent libacl1-dev libcap-dev libelf-dev liblocale-msgfmt-perl libncurses-dev libseccomp-dev libselinux1-dev libssl-dev locales-all manpages-dev net-tools parted python-is-python3 rsync sysstat sysvbanner texinfo unzip vim x11-apps"

export DEBS2="acct bsdmainutils clang-format expect faketime finger fuse kmod libc6-dev libfuse-dev lynx pkg-config sudo tmux util-linux"

echo "Updating system and installing utilities..." && \
time su -c "apt update && apt upgrade -y && apt install -y $DEBS1 && apt install -y $DEBS2 && apt install -y coreutils" && \
echo "Done updating system and installing utilities" && \
echo "Downloading NVM script" && \
time curl https://raw.githubusercontent.com/creationix/nvm/master/install.sh | bash && \
export NVM_DIR="$HOME/.nvm" && \
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
echo "Done downloading and installing NVM" && \
echo "Installing LTS Node JS" && \
time nvm install --lts && \
echo "Done installing LTS Node JS" && \
echo "Installing NPM and Yarn" && \
time su -c "apt install -y npm" && \
time npm install --global yarn && \
echo "Done. Environment ready."

Running a local preview

First, we'll install the packages required by docusaurus.

yarn install

To have a local preview that live-updates, run

yarn start

Optimized Deployment Build

To get an optimized deployment build, run

yarn build

To get a preview of this build, run

yarn serve

Deployment

Deployment instructions to Github Pages or other platforms can be found here