Skip to content

Repository files navigation

Surfer

Surfer is a Simple static file server. It comes with a commandline tool to upload files from your local folders and a webinterface to manage files directly on the server.

Development

git clone https://git.cloudron.io/s42/surfer.git
cd surfer
npm install
npm run build

To run the server, you need OIDC credentials from your OIDC provider.

export OIDC_ISSUER_ORIGIN="https://my.nebulon.space/openid"
export CLOUDRON_APP_ORIGIN="http://localhost:3000"
export OIDC_CLIENT_ID="surfer"
export OIDC_CLIENT_SECRET="secret"

node ./server.js /path/to/staticfolder /path/to/db.sqlite /path/to/favicon.png

File management

The admin interface is available under the /_admin location or you can upload files using the commandline tool.

First, install the surfer cli tool using npm.

npm -g install @cloudron/surfer

Configure the CLI with your app domain and a Cloudron app password (created in the Cloudron dashboard profile):

surfer config --server <url> --username <username> --password <appPassword>

Put some files:

surfer put [file]

Replace a site with the contents of a directory. With no flag this replaces Default (public/). --site-name publishes a named site. --domain creates that site first when it does not exist, and the domain must be an alias that is not already in use:

surfer deploy ./dist -m "Build from commit abc"
surfer deploy ./dist --site-name alpha
surfer deploy ./dist --site-name alpha --domain alpha.example.com

About

Simple static file server with cli and webinterface. This is just a mirror repo

Resources

Stars

63 stars

Watchers

5 watching

Forks

Releases

Packages

Used by

Contributors

Languages