This package makes it easy to create micro-applications for Sandstorm, a self-hostable web productivity suite.
It's a prototype of a Sandstorm application based on Mavo. Mavo is an original project developed by Lea Verou and CSAIL team at MIT.
"Mavo is a language that lets you create and edit interactive websites and apps with nothing more than HTML. Mavo allows you to make websites editable and saveable to the cloud via Github, DropBox or other services" … and Sandstorm, why not!
Sandstorm offers the ability to create new derivative micro-applications and customize existing.
Mavo extends the syntax of HTML to describe Web applications that manage, store, and transform data.
It is quite possible to run the micro-app outside of Sandstorm with Go, this is convenient to build the micro-app skeleton. To do that, from the root directory, launch :
go run microapp.go
- access the micro-app with your browser:
http://localhost:8000
On you Sandstorm server upload the last spk package like new app and launch some grains with.
For each each Sandstorm grain (in progress) :
- admin grain can edit, create and delete pages ; publish and unpublish static pages
- editor can update data with mavo interface
- viewer can view pages
- the Sandstorm backend storage of mavo data is not yet implemented
Launch a local Sandstorm instance :
- Install Vagrant.
- Install VirtualBox .
- Install Vagrant-SPK.
- Clone this repo and from the top-level directory, run:
vagrant-spk vm up
to start a virtual Linux machine containing Sandstormvagrant-spk dev
to make this app available in development mode, then your system is running a Sandstorm instance:- You should visit it in your web browser now by opening this link: http://local.sandstorm.io:6080
- Log in with a dev account, choose Alice (admin) as the user to sign in with
- Click the Micro App icon, then Create new instance to spin up a new micro-app instance.
To create a Sandstorm package (SPK) file, containing the app and all its dependencies.
- Stop the
vagrant-spk dev
server : typeCtrl-C
. - Add your public key in
.sandstorm/sandstorm-pkgdef.capnp
. You can generated it withvagrant-spk keygen
command. - To create the SPK file, run:
vagrant-spk pack ~/export-path/package.spk
You can upload this spk file inside your own Sandtorm server to test it.
This application uses the following libraries:
- Mavo — an HTML-based language for creating web applications without programming.
- Goland — Go pieces of code by the Go Authors and community.
- Slideout — A slideout navigation menu for web apps.
The backend is inspired by the Falafel65 PHP adaptor for Mavo.
- learning Go ;)
- Go storage backend for Mavo data
- Documentation
- Implement Sandstorm roles for each each grain (may be limited by Mavo) :
- Admins can edit code pages ; publish and unpublish static pages
- User can update data with mavo interface
- Visitor can view pages