11 - name: fetch git submodules
12 image: node:15-alpine3.12
15 - git submodule update --init --recursive --remote
18 image: ekidd/rust-musl-builder:1.47.0
21 - chown 1000:1000 . -R
23 - name: check formatting
24 image: rustdocker/rust:nightly
26 - /root/.cargo/bin/cargo fmt -- --check
29 image: ekidd/rust-musl-builder:1.47.0
31 - cargo clippy --workspace --tests --all-targets --all-features -- -D warnings -D deprecated -D clippy::perf -D clippy::complexity -D clippy::dbg_macro
34 image: ekidd/rust-musl-builder:1.47.0
36 LEMMY_DATABASE_URL: postgres://lemmy:password@database:5432/lemmy
41 - sudo apt-get -y install --no-install-recommends espeak postgresql-client
42 - cargo test --workspace --no-fail-fast
45 image: ekidd/rust-musl-builder:1.47.0
48 - mv target/x86_64-unknown-linux-musl/debug/lemmy_server target/lemmy_server
50 - name: run federation tests
51 image: node:15-alpine3.12
53 LEMMY_DATABASE_URL: postgres://lemmy:password@database:5432
54 DO_WRITE_HOSTS_FILE: 1
56 - apk add bash curl postgresql-client
57 - bash api_tests/prepare-drone-federation-test.sh
62 - name: make release build and push to docker hub
65 dockerfile: docker/prod/Dockerfile
67 from_secret: docker_username
69 from_secret: docker_password
70 repo: dessalines/lemmy
72 auto_tag_suffix: linux-amd64
77 - name: push to docker manifest
78 image: plugins/manifest
81 from_secret: docker_username
83 from_secret: docker_password
84 target: "dessalines/lemmy:${DRONE_TAG}"
85 template: "dessalines/lemmy:${DRONE_TAG}-OS-ARCH"
96 image: postgres:12-alpine
99 POSTGRES_PASSWORD: password
111 - name: fetch git submodules
112 image: node:15-alpine3.12
115 - git submodule update --init --recursive --remote
118 image: rust:1.47-slim-buster
120 LEMMY_DATABASE_URL: postgres://lemmy:password@database:5432/lemmy
125 - apt-get -y install --no-install-recommends espeak postgresql-client libssl-dev pkg-config libpq-dev
126 - cargo test --workspace --no-fail-fast
129 # Using Debian here because there seems to be no official Alpine-based Rust docker image for ARM.
131 image: rust:1.47-slim-buster
134 - apt-get -y install --no-install-recommends libssl-dev pkg-config libpq-dev
136 - mv target/debug/lemmy_server target/lemmy_server
138 - name: run federation tests
139 image: node:15-buster-slim
141 LEMMY_DATABASE_URL: postgres://lemmy:password@database:5432
142 DO_WRITE_HOSTS_FILE: 1
144 - mkdir -p /usr/share/man/man1 /usr/share/man/man7
146 - apt-get -y install --no-install-recommends bash curl libssl-dev pkg-config libpq-dev postgresql-client libc6-dev
147 - bash api_tests/prepare-drone-federation-test.sh
152 - name: make release build and push to docker hub
153 image: plugins/docker
155 dockerfile: docker/prod/Dockerfile.arm
157 from_secret: docker_username
159 from_secret: docker_password
160 repo: dessalines/lemmy
162 auto_tag_suffix: linux-arm64
167 - name: push to docker manifest
168 image: plugins/manifest
171 from_secret: docker_username
173 from_secret: docker_password
174 target: "dessalines/lemmy:${DRONE_TAG}"
175 template: "dessalines/lemmy:${DRONE_TAG}-OS-ARCH"
186 image: postgres:12-alpine
189 POSTGRES_PASSWORD: password