Automatic Setup of Solid CSS

Hello Solid Folks,

We are running experiments on solid CSS on 50 machines. I want a way to automate completing Solid-Sevre Setup when restarting the servers (

Currently, we have to do that manually which becomes quite hectic when doing that on 50 machines.

Is there any kind of request we could send to the servers so the Solid server can complete the setup?

Thanks in advance for your great help and support.

You should change your CSS configuration: see also the configuration generator: Community Solid Server configuration tool

  • Miscellaneous > Setup > Disabled

Then you can just use a POST request according to the Solid spec to generate a pod
Here is an example JavaScript example:

var myHeaders = new Headers();
myHeaders.append("Content-Type", "application/json");

var raw = JSON.stringify({
  "podName": "pod-test",
  "email": "",
  "password": "pod-test",
  "confirmPassword": "pod-test",
  "register": true,
  "createPod": true,
  "createWebId": true

var requestOptions = {
  method: 'POST',
  headers: myHeaders,
  body: raw,
  redirect: 'follow'

fetch("http://localhost:3000/idp/register/", requestOptions)
  .then(response => response.text())
  .then(result => console.log(result))
  .catch(error => console.log('error', error));

Or with curl

curl --location 'http://localhost:3000/idp/register/' \
--header 'Content-Type: application/json' \
--data-raw '{
      "podName": "pod-test",
      "email": "",
      "password": "pod-test",
      "confirmPassword": "pod-test",
      "register": true,
      "createPod": true,
      "createWebId": true

You could probably also use templates to not have to do an additional request after starting the server:
See also the configuration generator > additional customization > pod template folder
I have no experience with that though, but you can play around with it and see if that helps for your case.

1 Like