Skip to content

Commit

Permalink
Build as docker image
Browse files Browse the repository at this point in the history
  • Loading branch information
jreyes33 committed Dec 10, 2021
1 parent 8f8bea6 commit 84dffdf
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
.git
.github
.gitignore
/examples
/target
/tests
*.swp
Dockerfile
11 changes: 11 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
FROM rust:1-alpine AS builder

WORKDIR /usr/src/quilt
RUN apk add build-base
ENV RUSTFLAGS="-C link-arg=-s"
COPY . .
RUN cargo install --path .

FROM scratch
COPY --from=builder /usr/local/cargo/bin/quilt /usr/local/bin/quilt
ENTRYPOINT ["quilt"]
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,16 @@ A programming language

## Installation

Using `cargo`:
```
cargo install quilt-lang
```

Using `docker`:
```
docker run --rm ghcr.io/quilt-lang/quilt
```

## Usage

```
Expand All @@ -42,6 +48,7 @@ quilt --pixel-size 20 examples/hello_world_x20.png

- Run all checks: `make check`
- Scale images using ImageMagick: `convert -scale 500% foo.png foo_x5.png`
- Build docker image: `docker build . -t quilt:<TAG>`

## Documentation

Expand Down

0 comments on commit 84dffdf

Please sign in to comment.