https://github.com/vsoch/cs106b-builder
a Singularity container for build and run of QT-creator projects. Does not include any project content.
https://github.com/vsoch/cs106b-builder
container containers qt-creator reproducible singularity
Last synced: 12 months ago
JSON representation
a Singularity container for build and run of QT-creator projects. Does not include any project content.
- Host: GitHub
- URL: https://github.com/vsoch/cs106b-builder
- Owner: vsoch
- License: agpl-3.0
- Created: 2018-11-09T05:35:26.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-11-09T05:39:08.000Z (over 7 years ago)
- Last Synced: 2025-01-28T00:30:29.072Z (over 1 year ago)
- Topics: container, containers, qt-creator, reproducible, singularity
- Language: Shell
- Size: 15.6 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# CS106B-Builder
This is the CS106B-Builder - you can build a container and then use it to compile
and run a local project directory, without QT-Creator. We are using
a Singularity container instead of Docker so that we can more seamlessly use our
system display.
## 0. Install Singularity
You should first install Singularity. I recommend the verison 2.6 for a much
simpler install routine. Here is the [guide](https://www.sylabs.io/guides/2.6/user-guide/quick_start.html#quick-installation-steps), and instructions:
You'll need these dependencies
```bash
sudo apt-get update && \
sudo apt-get install \
python \
dh-autoreconf \
build-essential \
libarchive-dev
```
and then to install:
```bash
git clone https://github.com/sylabs/singularity.git
cd singularity
git fetch --all
git checkout 2.6.0
./autogen.sh
./configure --prefix=/usr/local
make
sudo make install
```
## 1. Build the Container
You can build this image locally, and note that you must have root permissions
todo so. This container could also be built and provided on [Singularity Hub](https://www.singularity-hub.org),
if appropriate.
```bash
sudo singularity build cs106b-builder Singularity
```
## 2. Extract your project
You will need to extract your project in the present working directory, or the
directory where you want to run your container. Usually this means unzipping
a project file to generate a subfolder. For example:
```bash
unzip cs106b-Pancakes.zip .
```
would create a folder with the name "Pancakes' - (or your project name)
## 3. Run the container
Next, you should run the container and bind the project folder (with the single .pro
file) inside. You can choose to build, run, or build and run. Note that if you
choose to build and run, it will only run after build given a successful build
(without errors). Here is how to ask for help, given a container called `cs106b-builder`:
```bash
singularity run cs106b-builder --help
```
To build the current folder:
```bash
singularity run --bind $PWD/Tiles:/code/Project cs106b-builder build
```
To then run!
```bash
singularity run --bind $PWD/Tiles:/code/Project cs106b-builder run
```
Or build and run:
```bash
singularity run --bind $PWD/Tiles:/code/Project cs106b-builder build run
```