Compare commits
No commits in common. "09f3afa35b9a6711a3968ed21fedc351e37c6c28" and "72d624ec95f00e0ecfccb1f37dabf52b9b270d7b" have entirely different histories.
09f3afa35b
...
72d624ec95
@ -1,22 +0,0 @@
|
||||
---
|
||||
title: "eval"
|
||||
tags: [ "basics" ]
|
||||
---
|
||||
|
||||
Compose a statement for execution.
|
||||
|
||||
```bash
|
||||
x='echo $y'
|
||||
echo $x
|
||||
y=dragon
|
||||
eval "$x"
|
||||
```
|
||||
|
||||
The results remain in the current shell, unlike sub-shells.
|
||||
|
||||
```bash
|
||||
b=basilisk
|
||||
sh -c 'echo $b'
|
||||
eval "g=goblin"
|
||||
echo $g
|
||||
```
|
@ -29,10 +29,11 @@ Edit `/etc/radicale/config`, changing the `[auth]` section from this:
|
||||
|
||||
...to this:
|
||||
```
|
||||
type = htpasswd
|
||||
#type = htpasswd
|
||||
```
|
||||
|
||||
Make sure the service is off, as people may be able to sign in without a password at this point.
|
||||
If the service is started, restart it to make sure nobody can sign in without a password.
|
||||
|
||||
|
||||
Next, find the `htpasswd` program.
|
||||
You might get it in the `apache` package or similar.
|
||||
@ -40,7 +41,7 @@ You might get it in the `apache` package or similar.
|
||||
`htpasswd` allows you to generate passwords for users, and place them in `/etc/radicale/users`.
|
||||
|
||||
```bash
|
||||
PASS="$(xkcdpass)"
|
||||
PASS="$(xkcdpass)
|
||||
htpasswd -nb $USER "$PASS" | sudo tee -a /etc/radicale/users
|
||||
echo "Your username is $USER"
|
||||
echo "Your password is $PASS"
|
||||
@ -95,12 +96,14 @@ Finally, replace the example `DOMAIN` with your actual domain name.
|
||||
```bash
|
||||
DOMAIN=whatever.com
|
||||
sudo sed -i "s/DOMAIN/$DOMAIN/g" /etc/nginx/sites-available/radicale
|
||||
|
||||
```
|
||||
|
||||
(optional: replace that `cal.` prefix with anything else)
|
||||
|
||||
Check nginx is happy:
|
||||
|
||||
|
||||
```bash
|
||||
sudo nginx -t
|
||||
```
|
||||
@ -112,6 +115,7 @@ sudo certbod -d cal.$DOMAIN
|
||||
|
||||
Start or restart both services:
|
||||
|
||||
|
||||
```bash
|
||||
sudo systemctl start radicale
|
||||
sudo systemctl restart nginx
|
||||
@ -119,4 +123,4 @@ sudo systemctl restart nginx
|
||||
|
||||
You should now be able to log into your calendar, and add it to a phone.
|
||||
|
||||
**NB:** you don't need the port number.
|
||||
NB: you don't need the port number.
|
||||
|
Loading…
Reference in New Issue
Block a user