Giter Site home page Giter Site logo

oshogbo / gramine-scaffolding Goto Github PK

View Code? Open in Web Editor NEW

This project forked from gramineproject/gramine-scaffolding

0.0 0.0 0.0 104 KB

A way to quickly start developing Gramine applications, or package existing apps into Docker/OCI containers.

License: GNU Lesser General Public License v3.0

Shell 1.83% JavaScript 0.64% Python 64.31% Java 0.68% C# 0.05% Jinja 32.49%

gramine-scaffolding's Introduction

Scaffolding for Gramine

Quick start (build from source)

Steps common to all distros

First, you need to install latest release of Gramine (at least 1.6) from upstream package repositories. In this example, codename is e.g., bookworm for Debian 12, but for Ubuntu this might be written as $(lsb_release -sc) substitution in the Gramine's instructions.

For example, when installing on Debian 12, add repositories like this:

sudo curl -fsSLo /usr/share/keyrings/gramine-keyring.gpg https://packages.gramineproject.io/gramine-keyring.gpg
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/gramine-keyring.gpg] https://packages.gramineproject.io/ bookworm main" \
| sudo tee /etc/apt/sources.list.d/gramine.list

sudo curl -fsSLo /usr/share/keyrings/intel-sgx-deb.asc https://download.01.org/intel-sgx/sgx_repo/ubuntu/intel-sgx-deb.key
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/intel-sgx-deb.asc] https://download.01.org/intel-sgx/sgx_repo/ubuntu jammy main" \
| sudo tee /etc/apt/sources.list.d/intel-sgx.list

Then you install Gramine as usual:

apt-get update
apt-get install gramine

Debian 12, Ubuntu 23.04

# sudo apt-get update && sudo apt-get install devscripts # if you didn't already
sudo apt-get build-dep .
debuild
sudo apt-get install ../gramine-scaffolding_*.deb
# gramine-sgx-gen-private-key # if you didn't already
scag-quickstart

Debian 11

# sudo apt-get update && sudo apt-get install devscripts # if you didn't already
sudo apt-get build-dep . -t bullseye-backports
debuild
sudo apt-get install ../gramine-scaffolding_*.deb
# gramine-sgx-gen-private-key # if you didn't already
scag-quickstart

Install into venv (for other distros, esp. for Ubuntu older than 23.04)

Unlike previous instructions, which build and install Scaffolding for all users in the system, this stanza installs the project into python's virtual environment. Those work only for single user, and either:

  • each time you restart your shell, you need to source the activate script again; or
  • call the binaries by their full path (e.g., .venv/bin/scag-build); or
  • add venv's bin/ directory to $PATH environment variable.

First, install gramine as described in https://gramine.rtfd.io/en/stable/installation.html#install-gramine-packages . If you haven't generated an SGX signing key, you may want to consider executing the following command

gramine-sgx-gen-private-key

Then:

sudo apt-get install docker.io python3-pip mmdebstrap
python3 -m venv .venv
source .venv/bin/activate
python3 -m pip install .
scag-quickstart

Development (editable install into virtualenv)

sudo apt-get install gramine docker.io python3-venv
python3 -m venv --system-site-packages .venv
source .venv/bin/activate
pip install --editable .
scag-quickstart

gramine-scaffolding's People

Contributors

woju avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.