Skip to content
This repository has been archived by the owner on Aug 14, 2023. It is now read-only.

Commit

Permalink
Remove some markdown linter warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
StefanScherer committed Nov 14, 2016
1 parent fb07b5b commit 19ec08f
Showing 1 changed file with 25 additions and 9 deletions.
34 changes: 25 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
[![Join the chat at https://gitter.im/hypriot/talk](https://badges.gitter.im/hypriot/talk.svg)](https://gitter.im/hypriot/talk?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[![Build Status](https://travis-ci.org/hypriot/image-builder-rpi.svg)](https://travis-ci.org/hypriot/image-builder-rpi)

This repo builds the SD card image with HypriotOS for the Raspberry Pi 1, 2, 3 and Zero. You can find released versions of the SD card image here in the GitHub releases page. To build this SD card image we have to
This repo builds the SD card image with HypriotOS for the Raspberry Pi 1, 2, 3
and Zero. You can find released versions of the SD card image here in the GitHub
releases page. To build this SD card image we have to

* take the files for the root filesystem from [`os-rootfs`](https://github.com/hypriot/os-rootfs)
* take the empty raw filesystem from [`image-builder-raw`](https://github.com/hypriot/image-builder-raw) with the two partitions
Expand All @@ -16,12 +18,18 @@ Here is an example how all the GitHub repos play together:

## Contributing

You can contribute to this repo by forking it and sending us pull requests. Feedback is always welcome!
You can contribute to this repo by forking it and sending us pull requests.
Feedback is always welcome!

You can build the SD card image locally with Vagrant.

### Setting up build environment
Make sure you have [vagrant](https://docs.vagrantup.com/v2/installation/) and [docker-machine](https://docs.docker.com/machine/install-machine/) installed. Then run the following command to create the Vagrant box and the Docker Machine connection. The Vagrant box is needed as a vanilla boot2docker VM is not able to run guestfish inside. Use `export VAGRANT_DEFAULT_PROVIDER=virtualbox` to strictly create a VirtualBox VM.

Make sure you have [vagrant](https://docs.vagrantup.com/v2/installation/) and [docker-machine](https://docs.docker.com/machine/install-machine/) installed.
Then run the following command to create the Vagrant box and the Docker Machine
connection. The Vagrant box is needed as a vanilla boot2docker VM is not able to
run guestfish inside. Use `export VAGRANT_DEFAULT_PROVIDER=virtualbox` to
strictly create a VirtualBox VM.

```bash
make docker-machine
Expand All @@ -35,40 +43,48 @@ eval $(docker-machine env image-builder-rpi)

### Build the SD card image

From here you can just make the SD card image. The output will be written and compressed to `hypriotos-rpi-dirty.img.zip`.
From here you can just make the SD card image. The output will be written and
compressed to `hypriotos-rpi-dirty.img.zip`.

```bash
make sd-image
```

### Run Serverspec tests

To test the compressed SD card image with [Serverspec](http://serverspec.org) just run the following command. It will expand the SD card image in a Docker container and run the Serverspec tests in `builder/test/` folder against it.
To test the compressed SD card image with [Serverspec](http://serverspec.org)
just run the following command. It will expand the SD card image in a Docker
container and run the Serverspec tests in `builder/test/` folder against it.

```bash
make test
```

### Run integration tests

Now flash the SD card image and boot up a Raspberry Pi. Run the [Serverspec](http://serverspec.org) integration tests in `builder/test-integration/` folder against your Raspberry Pi. Set the environment variable `BOARD` to the IP address or host name of your running Raspberry Pi.
Now flash the SD card image and boot up a Raspberry Pi. Run the [Serverspec](http://serverspec.org) integration tests in `builder/test-integration/`
folder against your Raspberry Pi. Set the environment variable `BOARD` to the
IP address or host name of your running Raspberry Pi.

```bash
flash hypriotos-rpi-dirty.img.zip
BOARD=black-pearl.local make test-integration
```

This test works with any Docker Machine, so you do not need to create the Vagrant box.
This test works with any Docker Machine, so you do not need to create the
Vagrant box.

## Deployment

For maintainers of this project you can release a new version and deploy the SD card image to GitHub releases with
For maintainers of this project you can release a new version and deploy the
SD card image to GitHub releases with

```bash
TAG=v0.0.1 make tag
```

After that open the GitHub release of this version and fill it with relevant changes and links to resolved issues.
After that open the GitHub release of this version and fill it with relevant
changes and links to resolved issues.

## License

Expand Down

0 comments on commit 19ec08f

Please sign in to comment.