43 lines
1.4 KiB
Markdown
43 lines
1.4 KiB
Markdown
# foundryvtt_container
|
|
If you don't want to build and host your own container image feel free to skip ahead and leverage the publicly hosted container. Head over to "Running the Container" if this is the better use-case for you.
|
|
|
|
## Builidng the Container
|
|
Just run the script with the URL and Version declared as follows:
|
|
```bash
|
|
./build.sh -U $FOUNDRY_URL -I -v $VERSION
|
|
```
|
|
|
|
## Running the Container
|
|
When setting hostname, make sure you use the hostname of the baremetal server or VM that you are running the container on. Otherwise you will need to accept the license at each initialization.
|
|
Assuming you are using rootless like I am, you'll need to have created a rootless user and enabled lingering.
|
|
I'm using quadlets, so here's an example quadlet:
|
|
```bash
|
|
# in your rootless podman container directory, ie: /etc/containers/systemd/users/${USER_UID}/
|
|
# foundryvtt.container
|
|
[Unit]
|
|
Description=FoundryVTT Custom Container
|
|
Requires=var-mnt-data01.mount
|
|
|
|
[Container]
|
|
AutoUpdate=registry
|
|
HostName=${VM_HOSTNAME}
|
|
Image=registry.belway.me/public/foundryvtt_container:latest
|
|
Label=registry
|
|
Network=slirp4netns:port_handler=slirp4netns
|
|
PublishPort=30000:30000
|
|
Timezone=America/Montreal
|
|
Volume=${YOUR_DATA_DIRECTORY_HERE}:/foundryvtt/foundrydata:z
|
|
|
|
[Service]
|
|
Restart=always
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target default.target
|
|
```
|
|
|
|
Then as the user, run:
|
|
```bash
|
|
systemctl --user daemon-reload
|
|
systemctl --user start foundryvtt
|
|
```
|