updates README with new Podman instructions
This commit is contained in:
28
README.md
28
README.md
@@ -10,17 +10,35 @@ Structure:
|
|||||||
└── infrastructure: The infrastructure of my website as code
|
└── infrastructure: The infrastructure of my website as code
|
||||||
```
|
```
|
||||||
|
|
||||||
## Running
|
## Running with Podman
|
||||||
|
|
||||||
To run with Docker or Podman:
|
These instructions will probably work with Docker, too: just substitute `podman`
|
||||||
|
for `docker` in all the commands.
|
||||||
|
|
||||||
|
To run with Podman, first set up your environment variables. Copy `example.env`
|
||||||
|
to `.env` and edit the values accordingly.
|
||||||
|
|
||||||
|
Then, create the `remote_smtp_password` secret, storing the password for the
|
||||||
|
remote SMTP server which will send the contact emails on behalf of the website.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker build -t joeac-net .
|
sudo podman secret create remote_smtp_password /path/to/remote/smtp/password
|
||||||
docker run joeac-net [port]:4321
|
|
||||||
```
|
```
|
||||||
|
|
||||||
To run with Node:
|
Now build and start the containers:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
sudo podman-compose build && sudo podman-compose up -d
|
||||||
|
```
|
||||||
|
|
||||||
|
## Running on the host machine
|
||||||
|
|
||||||
|
To run on the host machine, first, as before, set up your environment variables
|
||||||
|
by copying `example.env` to `.env` and editing the values as appropriate.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
npm run start
|
npm run start
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Note that emails may not work locally without further setup. These instructions
|
||||||
|
are of course woefully incomplete.
|
||||||
|
|||||||
20
example.env
Executable file
20
example.env
Executable file
@@ -0,0 +1,20 @@
|
|||||||
|
# The username for authenticating to the local SMTP server
|
||||||
|
# Recommended to be the same as REMOTE_SMTP_USER, else the remote may reject it
|
||||||
|
LOCAL_SMTP_USER=
|
||||||
|
|
||||||
|
# The envelope-from used by the local SMTP server
|
||||||
|
# Recommended to be the same as REMOTE_SMTP_USER, else the remote may reject it
|
||||||
|
LOCAL_SMTP_ENVELOPE_FROM=
|
||||||
|
|
||||||
|
# The host of the remote SMTP server, e.g. smtp.gmail.com
|
||||||
|
REMOTE_SMTP_HOST=
|
||||||
|
|
||||||
|
# The port of the remote SMTP server: usually 25, 465, or 587
|
||||||
|
REMOTE_SMTP_PORT=
|
||||||
|
|
||||||
|
# The username for authenticating to the remote SMTP server
|
||||||
|
# Usually the email address which will be sending the contact emails
|
||||||
|
REMOTE_SMTP_USER=me@joeac.net
|
||||||
|
|
||||||
|
# The email address where contact emails will be sent
|
||||||
|
CONTACT_MAILBOX=me@joeac.net
|
||||||
Reference in New Issue
Block a user