# I get a permission denied when trying to SSH
Unfortunately SHA-2 RSA keys are not currently supported.
Unfortunately, due to a shortcoming in Go’s x/crypto/ssh package, we not currently support access via new SSH RSA keys: only the old SHA-1 ones will work. Until we sort this out you’ll either need an SHA-1 RSA key or a key with another algorithm, e.g. Ed25519. Not sure what type of keys you have? You can check with the following:
$ find ~/.ssh/id_*.pub -exec ssh-keygen -l -f {} \;
If you’re curious about the inner workings of this problem have a look at:
# Generating a new SSH key
ssh-keygen -t ed25519 -C "your_email@example.com"
- When you're prompted to "Enter a file in which to save the key," press Enter. This accepts the default file location.
- At the prompt, type a secure passphrase.
# CLI Commands
Our CLI commands are currently in active development so the list of available commands are changing.
The best way to learn about all the commands we support is via an SSH command:
ssh pgs.sh help
Having said that, we do want to demonstrate the power of pgs.sh by discussing design goals.
All of our SSH commands are safe-by-default. Meaning, they never mutate server state by default.
This provides users an opportunity to experiment with our commands to see how they work. In order to
actually trigger server mutations, every command must be appended with --write
.
Further, we want to make sure users are able to manage their static sites exclusively from SSH commands. Below is list of features we support via SSH commands:
- Storage usage stats:
ssh
@pgs.sh stats - List all projects (and their links):
ssh
@pgs.sh ls - List all project dependencies:
ssh
@pgs.sh depends project-x - Link a project:
ssh
@pgs.sh link project-x project-y - Unlink a project:
ssh
@pgs.sh unlink project-x - Delete a project (and all assets):
ssh
@pgs.sh rm project-x - Delete all projects matching a prefix (except projects that have linked projects):
ssh
@pgs.sh prune prefix
# What file types are supported?
- html
- htm
- css
- js
- jpg
- png
- gif
- webp
- svg
- ico
- json
- txt
- otf
- ttf
- woff
- woff2
- md
- rss
- xml
- atom
- map
- webmanifest
# User-defined Redirects
We support custom redirects via a special file _redirects
.
Read more about it at netflify
# Single-Page Applications (SPAs)
pgs supports SPAs! Upload a _redirects
file your project:
/* /index.html 200
# Setup a custom domain
A blog can be accessed from a custom domain. HTTPS will be automatically enabled and a certificate will be retrieved from Let's Encrypt. In order for this to work, 2 DNS records need to be created:
CNAME for the domain to pgs (subdomains or DNS hosting with CNAME flattening) or A record
CNAME subdomain.yourcustomdomain.com -> pgs.sh
Resulting in:
subdomain.yourcustomdomain.com. 300 IN CNAME pgs.sh.
And a TXT record to tell Prose what blog is hosted on that domain at the subdomain entry _pgs
TXT _pgs.subdomain.yourcustomdomain.com -> yourusername
Resulting in:
_pgs.subdomain.yourcustomdomain.com. 300 IN TXT "hey"