Samples
Language samples.
Purpose
The purpose of this module is to showcase intermediate and advanced concepts of the language.
This is not a complete or whole set and is not meant as a finished library nor production ready.
This is meant for learnings and tutorials that can be successfully compiled and executed.
Purpose of which is to use as a collection of code snippets that cover a broad list of categories.
Installation
To configure VS Code with GCC, GDB, and WSL, follow this link
To install dependencies, run:
./install.sh
Docker
There is a Dockerfile that creates a full install of all dependencies for a self-hosted runner.
To install the self-hosted runner, a TOKEN parameter needs tobe supplied, which provides authentication.
Get the token, follow self-hosted runner instructions below.
./docker/docker_build <TOKEN> <REPO_TAG>
./docker/docker_build <TOKEN> github.actions.runner.ubuntu-22.04
Container Start Command
The following command may need to be added in the right place in order to start the container:
/etc/init.d/boot-script start
Go
Go development tutorial can be found here
Buf and Connect
Follow these links to setup Buf and Connect-go to auto generate API code from .proto files.
To keep versions updated, install go-mod-upgrade
Run
To execute this module in Linux, run:
python3 test_runner.py
Programming Languages
Intermediate+ Level Skills
- C++
- Python
- Go
GitHub
The following is a list of GitHub workflows supported:
Workflow |
Description |
build_libraries.yaml |
Installs dependencies, libraries, and uploads artifacts. |
build.yaml |
Installs dependencies, downloads artifacts, builds, and runs all tests. |
Self-Hosted Runners
Add self-hosted runners by following this link
Start Service on Boot
Configure the self-hosted runner application as a service to start on boot here
Note: Handle the User used to start the self-hosted runner applications. The user may be set in /etc/systemd/system/actions.runner.<githubuser>-<repo>.<host>.service
To find the service name in the list of running services on Linux systems:
$ systemctl --type=service | grep actions.runner
actions.runner.<hostname>.service loaded active running GitHub Actions Runner (<hostname>)
Non-systemd Boot Systems
If your system boots with init.d, perform the following steps to launch the actions runner as a service:
- Copy boot-script to init.d:
sudo cp scripts/init.d/boot-script /etc/init.d
- Update paths as necessary.
- Copy actions.runner.service.template to init.d:
sudo cp scripts/init.d/actions.runner.service.template /etc/init.d
- Make the script executable:
sudo chmod +x /etc/init.d/boot-script
- Update the rc.d system links (to start script on boot):
sudo update-rc.d boot-script defaults
If the above fails, link it to the booter:
sudo ln -s /etc/init.d/boot-script /etc/rc2.d/S20boot-script
- (Optional) Start the service:
sudo service boot-script start
- (Optional) Check service status
sudo service boot-script status
If all else fails, use manual mode to start the service:
./bin/runsvc.sh ./bin/actions.runner.service.template