Skip to content

Instantly share code, notes, and snippets.

View michielbdejong's full-sized avatar

Michiel de Jong michielbdejong

View GitHub Profile
@michielbdejong
michielbdejong / Basic Nextcloud server on Ubuntu
Last active September 30, 2022 08:08
Steps to setting up a Nextcloud server from scratch using an Ubuntu-based VPS
There are a many ways to run Nextcloud:
* on localhost, on a VPS, or in a Docker container
* using Apache, nginx, `php -S`
* from git, from zip, via snap
## On a VPS, using Snap
* Follow https://www.digitalocean.com/community/tutorials/how-to-install-and-configure-nextcloud-on-ubuntu-22-04
## On a VPS, using Docker
* With nc-sciencemesh enabled: https://github.com/pondersource/sciencemesh-nextcloud#demo-setup
@prefix : <#>.
@prefix n0: <http://www.w3.org/ns/auth/acl#>.
@prefix c: <https://michielbdejong.inrupt.net/profile/card#>.
@prefix c0: <https://michielbdejong.solid.community/profile/card#>.
@prefix c1: </profile/card#>.
@prefix c2: <https://sstratsianis.solid.community/profile/card#>.
@prefix c3: <https://timbl.inrupt.net/profile/card#>.
@prefix c4: <https://timbl.solid.community/profile/card#>.
@prefix c5: <https://www.w3.org/People/Berners-Lee/card#>.
@prefix c6: <https://angelo.veltens.org/profile/card#me>.
import { fetchDocument } from 'tripledoc';
async function createAclDoc(webId: string, resourceUri: string, otherAuthMode: string, otherAuthClass: string, recursive = false) {
const resourceDoc = await fetchDocument(resourceUri);
console.log('got doc', resourceUri);
const aclRef = resourceDoc.getAclRef();
console.log('got acl ref', webId, resourceUri, aclRef);
if (!aclRef) {
throw new Error('Could not determine ACL ref for friends list');
}

To split your identity from your pod:

Set up a pod

It doesn't have to support IDP functionality. I used https://github.com/inrupt/pod-server and deployed it to https://pod-server.herokuapp.com

Set up a WebID

I registered the user 'michiel-at-heroku' on https://inrupt.net, then used a private browsing tab to log in as that user (so that it wouldn't log me in as my main https://michielbdejong.inrupt.net identity) and edited https://michiel-at-heroku.inrupt.net/profile/card by adding three prefixes (pod:, inbox: and settings:) and linking to those:

I commit to my contributions to wac-ldp-kit being available into the MIT license.
<section class="text-center">
<h2 id="tmp-title">Fiduciary License Agreement 2.0</h2>
<span id="tmp-subtitle-based">based on the</span>
<h2 id="tmp-subtitle"><span id="tmp-contributor-type">Individual</span> Contributor <span id="tmp-contributor-exclusivity-1">exclusive</span> License Agreement</h2>
<h2 id="tmp-subtitle-patent">(including the <span id="tmp-patent-option">Traditional Patent License</span> OPTION)</h2>
</section>
<p>Thank you for your interest in contributing to <span id="tmp-beneficiary-name">inrupt</span>'s <span id="tmp-project-name">wac-ldp-kit</span> ("We" or "Us").</p>
<p>The purpose of this contributor agreement ("Agreement") is to clarify and document the rights granted by contributors to Us. To make this document effective, please follow the instructions at <span id="tmp-submission-instructions">https://github.com/inrupt/wac-ldp-kit</span>.</p>
0x3284166218919725e0d27da8dc54b9e8c2e3c31b
[michiel@mbp ~]$ mkdir exampleForDavid
[michiel@mbp ~]$ cd exampleForDavid/
[michiel@mbp ~/exampleForDavid]$ npm install ilp-packet
npm WARN saveError ENOENT: no such file or directory, open '/Users/michiel/exampleForDavid/package.json'
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN enoent ENOENT: no such file or directory, open '/Users/michiel/exampleForDavid/package.json'
npm WARN exampleForDavid No description
npm WARN exampleForDavid No repository field.
npm WARN exampleForDavid No README data
npm WARN exampleForDavid No license field.
@michielbdejong
michielbdejong / gist:f300080b7a9f9d0a20f43a0a74ebce56
Last active November 2, 2017 15:59
main argument against removing connector-implemented quoting protocols

This is a response to Evan's question on Slack:

[what is the] main argument against removing connector-implemented quoting protocols

Interesting question! I still think the three main design principles of Interledger are:

  • we only care about payments
  • the complexity is in the connectors
  • users trust their own ledger; connectors are trustless

Alice wants Bob's balance on ledger B to go up by a certain amount. She trusts Bob to report whether this has happened or not. She is willing to pay a translated amount from her balance on ledger A, but if that

0xe32dd3accd5cad0f4ee4dc164363c52b81deff92