Scripts in this repository will automate the bootstrap and setup of ROS build farm hosts.
- Ubuntu 20.04
These scripts must be run as root on hosts that meet the [requirements for a ROS build farm deployment][requirements]. Before running the scripts you must have a [configured chef repository][chef-repo-setup].
[requirements]: # TODO [chef-repo-setup]: # TODO
- Clone this script repository to your target host.
- Copy
configuration.bash.example
intoconfiguration.bash
and populate with the necessary values. - Run
./bootstrap
- Run
./configure CHEF_REPO CHEF_BRANCH CHEF_ENVIRONMENT CHEF_SOLO_FILE
To refresh a host which has been configured previously
- Run
./configure
Your chef repository will contain sensitive contents such as ssh private keys, gpg private keys, passwords, and tokens. Making that information public is strongly discouraged.
SSH agent forwarding can be used to grant temporary access to the configuration repository for the duration of configuration.
- Set up your local ssh-agent
- Add a key to your local agent which has access to your chef repository
- Connect to your build farm host with ssh agent forwarding enabled using the
-A
command line flag orForwardAgent yes
configuration option - If using
sudo
for an interactive root shell usesudo -Es
to preserve the environment variables containing SSH agent socket information.
All scripts populate their environment variables through configuration.bash
. Some of these configurations can be overwritten through args.
Boostrap the necessary dependencies to configure the agent:
- Chef
- Git
- Curl
Overrides configuration value with custom CHEF_VERSION
sudo ./bootstrap CHEF_VERSION
Skips manual validation of OMNITRUCK
script execution.
sudo RUN_OMNITRUCK=1 ./bootstrap
Executes the chef cookbooks and configures the agent.
This overrides all values with the corresponding args values passed on execution.
./configure CHEF_REPO CHEF_BRANCH CHEF_ENVIRONMENT CHEF_SOLO_FILE