Quick Setup Guide
Contents:
|
In this configuration, we will show you how to install Fuego and run a test on a 'docker' board, which is the docker container where Fuego itself is running on your host machine.
Obviously, this is not useful for testing any real hardware. It is intended only as a demonstration of Fuego functionality.
For instructions to set up a real board, try the Fuego Quickstart Guide or the Installing Fuego page.
Overview [edit section]
The overview of the steps is:- 1. install pre-requisite software
- 2. download the Fuego repository
- 3. build your Fuego container
- 4. start the container
- 5. add the 'docker' board to Jenkins
- 6. add some sample tests
- 7. access the Jenkins interface
- 8. run a test
These steps are described below.
Step details [edit section]
To retrieve the Fuego software and create the docker image for it, you need to have git and docker installed on your system.On Ubuntu, try the following commands:
$ sudo apt install git docker.io
To download Fuego, and build and start the container, type the following commands at a Linux shell prompt:
$ git clone https://bitbucket.org/fuegotest/fuego.git $ cd fuego $ ./install.sh $ ./start.sh
The third step (with ./install.sh) will take some time - about 45 minutes on an average Linux machine. This is building the "Fuego" distribution of Linux (based on Debian) and putting it in the Fuego docker container. You will also need a connection to the Internet with fairly decent bandwidth.
When you run the 'start.sh' script, the terminal will be placed at a shell prompt, as the root user inside the docker container. The container will run until you exit this shell. You should leave it running for the duration of your testing.
The next steps populate the Jenkins system objects used for testing:
At the shell prompt inside the container type the following:
<container-prompt># ftc add-node -b docker <container-prompt># ftc add-jobs -b docker -t Functional.batch_smoketest
This will add the 'docker' node (representing the 'docker' Fuego board) in the Jenkins interface and a small set of tests.
The "smoketest" batch test has about 20 tests that exercise a variety of features in a Linux system. After running these commands, a set of jobs will appear in the Jenkins interface.
$ firefox http://localhost:8090/fuego
To access the Fuego interface (Jenkins) you can use any browser - not just Firefox. By default the Fuego interface runs on your host machine, on port 8090, with URL path "/fuego".
In your browser, you should see a screen similar to the following:
Run a test [edit section]
To run a job manually, do the following:- Go to the Jenkins dashboard (in the main Jenkins web page),
- Select the job (which includes the board name and the test name)
- Click “Build job” (Jenkins refers to running a test as "building" it.)
A few very simple jobs you might start with are:
- Functional.hello_world
- Benchmark.Drhystone
You can also start a test manually by clicking on the circle with a green triangle, on the far right of the line with the job name, in the Jenkins dashboard.
When you run a test, the test software is built from source, sent to the machine (in this case the Fuego docker container), and executed. Then the results are collected, analyzed, and displayed in the Jenkins interface.
When the test has completed, the status will be shown by a colored ball by the side of the test in the dashboard. Green means success, red means failure, and grey means the test did not complete (it was not run or it was aborted). You can get details about the test run by clicking on the links in the history list. You can see the test log (what the actual test program output on the target), by clicking on "testlog". You can see the steps Fuego took to execute the test by clicking on the "console log" link on the job page. And you can see the formatted results for a job, and job details (like start time, test information, board information, and results) in the 'run.json' file.
What do do next? [edit section]
In order to use Fuego in a real Continuus Integration loop, you need to do a few things:- configure Fuego to work with your own board or product
- customize benchmark thresholds and functional baselines for your board
- configure Fuego jobs to be triggered after the board is installed with new software to test
Fuego does not currently have support for provisioning boards (that is, installing the "software under test" to the board). Usually, Fuego users create their own Jenkins job which provisions the board, and then triggers Fuego jobs, after the new software is installed on the board.
See further instructions see the Fuego Quickstart Guide, Adding a board, Adding a toolchain or the Installing Fuego page.