diff --git a/xpost/.config/docker.env b/xpost/.config/docker.env new file mode 100644 index 0000000..e69de29 diff --git a/xpost/README.md b/xpost/README.md new file mode 100644 index 0000000..06d2af1 --- /dev/null +++ b/xpost/README.md @@ -0,0 +1,17 @@ +# xpost + +atm the image must be built locally. this can be done like this: + +``` +git clone https://tangled.sh/@melontini.me/xpost xpost +cd xpost +docker build -t melontini/xpost:latest -f Containerfile . +``` + +for podman: + +`podman build --security-opt label=disable -t melontini/xpost:latest -f Containerfile .` + +example `compose.yaml` assumes that data dir is `./data`, and env file is `./.config/docker.env`. add `:Z` to volume mounts for podman. + +the settings are pre-configured for mastodon-wss -> bsky crossposting, posts with links to bsky.app, deer.social and anartia are skipped. add `MASTODON_INSTANCE`, `MASTODON_TOKEN`, `BLUESKY_HANDLE` and `BLUESKY_APP_PASSWORD` to `docker.env` \ No newline at end of file diff --git a/xpost/compose.yml b/xpost/compose.yml new file mode 100644 index 0000000..e34e5a7 --- /dev/null +++ b/xpost/compose.yml @@ -0,0 +1,7 @@ +services: + xpost: + image: melontini/xpost:latest + restart: unless-stopped + env_file: ./.config/docker.env + volumes: + - ./data:/app/data \ No newline at end of file diff --git a/xpost/data/settings.json b/xpost/data/settings.json new file mode 100644 index 0000000..1f4351d --- /dev/null +++ b/xpost/data/settings.json @@ -0,0 +1,32 @@ +{ + "input": { + "type": "mastodon-wss", + "instance": "env:MASTODON_INSTANCE", + "token": "env:MASTODON_TOKEN", + "options": { + "allowed_visibility": [ + "public", + "unlisted" + ], + "regex_filters": [ + "https?://bsky\\.app(?![\\.-]\\w)", + "https?://deer\\.social(?![\\.-]\\w)", + "https?://anartia\\.kelinci\\.net(?![\\.-]\\w)" + ] + } + }, + "outputs": [ + { + "type": "bluesky", + "handle": "env:BLUESKY_HANDLE", + "app-password": "env:BLUESKY_APP_PASSWORD", + "options": { + "quote_gate": false, + "thread_gate": [ + "everybody" + ], + "encode_videos": true + } + } + ] +} \ No newline at end of file