Compare commits
5 commits
ba258cd3a7
...
9ab413c614
Author | SHA1 | Date | |
---|---|---|---|
9ab413c614 | |||
99603fc4fc | |||
9f22c9d6f1 | |||
e1477673b2 | |||
3a5763e40f |
4 changed files with 5 additions and 94 deletions
11
README.md
11
README.md
|
@ -26,12 +26,6 @@ cd dchat
|
|||
docker compose build
|
||||
```
|
||||
|
||||
#### Pull the prebuilt images
|
||||
|
||||
```shell
|
||||
docker compose pull
|
||||
```
|
||||
|
||||
### Configure environment
|
||||
|
||||
```shell
|
||||
|
@ -70,6 +64,11 @@ Invite the bot through the link provided in the container logs.
|
|||
docker compose logs bot
|
||||
```
|
||||
|
||||
### Permissions
|
||||
|
||||
After starting the stack, navigate to [localhost:8081](http://localhost:8081)
|
||||
and feel free to configure who and how much they can use the bot :)
|
||||
|
||||
## LICENSE
|
||||
|
||||
The software is licensed under the [MPL-2.0](LICENSE) license.
|
||||
|
|
54
build.sh
54
build.sh
|
@ -1,54 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
AUTHORS="Augusto Dwenger J. <dwenger@posteo.de>"
|
||||
URL="https://${REPO}"
|
||||
VENDOR="hamburghammer"
|
||||
|
||||
build() {
|
||||
CREATED=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
|
||||
REVISION=$(git rev-parse HEAD)
|
||||
|
||||
IMAGE_LATEST="${REPO}:latest"
|
||||
|
||||
if [ "$PUSH_LATEST" == "1" ]; then
|
||||
DOCKER_BUILD_ARGS="$DOCKER_BUILD_ARGS --push"
|
||||
fi
|
||||
|
||||
# shellcheck disable=SC2086
|
||||
docker buildx build \
|
||||
$DOCKER_BUILD_ARGS \
|
||||
-t $IMAGE_LATEST \
|
||||
--file Containerfile \
|
||||
--platform linux/amd64,linux/arm64 \
|
||||
--label "org.opencontainers.image.revision=${REVISION}" \
|
||||
--label "org.opencontainers.image.version=${TAG}" \
|
||||
--label "org.opencontainers.image.authors=${AUTHORS}" \
|
||||
--label "org.opencontainers.image.created=${CREATED}" \
|
||||
--label "org.opencontainers.image.source=${URL}" \
|
||||
--label "org.opencontainers.image.vendor=${VENDOR}" \
|
||||
--label "org.opencontainers.image.title=${TITLE}" \
|
||||
--label "org.opencontainers.image.description=${DESCRIPTION}" \
|
||||
. || exit $?
|
||||
|
||||
}
|
||||
|
||||
echo "start building bot"
|
||||
REPO="git.hhhammer.de/hamburghammer/dchat/bot"
|
||||
TITLE="dchat-bot"
|
||||
DESCRIPTION="A Discord bot to chat with ChatGPT from OpenAI"
|
||||
DOCKER_BUILD_ARGS="--target bot"
|
||||
build
|
||||
|
||||
echo "start building web"
|
||||
REPO="git.hhhammer.de/hamburghammer/dchat/web"
|
||||
TITLE="dchat-web"
|
||||
DESCRIPTION="A web API and UI for the dchat-bot configuration"
|
||||
DOCKER_BUILD_ARGS="--target web"
|
||||
build
|
||||
|
||||
echo "start building migration"
|
||||
REPO="git.hhhammer.de/hamburghammer/dchat/migration"
|
||||
TITLE="dchat-migration"
|
||||
DESCRIPTION="A migration tool for the dchat database"
|
||||
DOCKER_BUILD_ARGS="--target migration"
|
||||
build
|
3
ui/.vscode/extensions.json
vendored
3
ui/.vscode/extensions.json
vendored
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
"recommendations": ["Vue.volar", "Vue.vscode-typescript-vue-plugin"]
|
||||
}
|
31
ui/build.sh
31
ui/build.sh
|
@ -1,31 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
REPO="git.hhhammer.de/hamburghammer/dchat-ui"
|
||||
AUTHORS="Augusto Dwenger J. <dwenger@posteo.de>"
|
||||
URL="https://${REPO}"
|
||||
VENDOR="hamburghammer"
|
||||
TITLE="dchat-ui"
|
||||
DESCRIPTION="The Web-UI for dchat a Discord bot to chat with ChatGPT from OpenAI"
|
||||
CREATED=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
|
||||
REVISION=$(git rev-parse HEAD)
|
||||
|
||||
IMAGE_LATEST="${REPO}:latest"
|
||||
|
||||
# shellcheck disable=SC2086
|
||||
podman build \
|
||||
$DOCKER_BUILD_ARGS \
|
||||
-t $IMAGE_LATEST \
|
||||
--label "org.opencontainers.image.revision=${REVISION}" \
|
||||
--label "org.opencontainers.image.version=${TAG}" \
|
||||
--label "org.opencontainers.image.authors=${AUTHORS}" \
|
||||
--label "org.opencontainers.image.created=${CREATED}" \
|
||||
--label "org.opencontainers.image.source=${URL}" \
|
||||
--label "org.opencontainers.image.vendor=${VENDOR}" \
|
||||
--label "org.opencontainers.image.title=${TITLE}" \
|
||||
--label "org.opencontainers.image.description=${DESCRIPTION}" \
|
||||
. || exit $?
|
||||
|
||||
if [ "$PUSH_LATEST" == "1" ]; then
|
||||
podman push "${IMAGE_LATEST}"
|
||||
fi
|
||||
|
Loading…
Reference in a new issue