Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

change google to debian, add docker-compose file #6

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Use distroless as minimal base image to package the distrust binary
# Refer to https://github.com/GoogleContainerTools/distroless for more details
FROM gcr.io/distroless/static:nonroot
FROM debian:buster-slim
WORKDIR /
COPY distrust /
USER nonroot:nonroot
RUN useradd -ms /bin/bash nonroot

EXPOSE 3000

Expand Down
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,10 @@ To run distrust, copy the `distrust.example.yml` file to `distrust.yml` and cust
./distrust
```

## Installation
You can also use a container engine like podman or docker to run distrust

### Running using podman
```sh
podman run -d \
--name distrust \
Expand All @@ -22,6 +24,22 @@ podman run -d \
ghcr.io/parkour-vienna/distrust:$VERSION
```

### Running using docker-compose

Download a release

```sh
export VERSION=0.0.5
curl https://github.com/Parkour-Vienna/distrust/releases/download/v$VERSION/distrust_$VERSION_Linux_x86_64.tar.gz
tar zxvf distrust_$VERSION_Linux_x86_64.tar.gz
```

Build the image: `docker-compose build`

Up and running: `docker-compose up`

Generate a new key: `docker-compose exec distrust ./distrust genkey`

## Configuration

### Configuring Discourse
Expand Down
8 changes: 8 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
version: '3'
services:
distrust:
build: .
volumes:
- ./distrust.yml:/distrust.yml:ro
ports:
- "3000:3000"