-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathEarthfile
More file actions
64 lines (55 loc) · 1.88 KB
/
Copy pathEarthfile
File metadata and controls
64 lines (55 loc) · 1.88 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
VERSION 0.8
FROM alpine
###############################################################################
# Primary Targets
###############################################################################
build-image:
ARG TAG=dev
FROM DOCKERFILE \
-f docker/Dockerfile \
docker
SAVE IMAGE --push ghcr.io/marinatedconcrete/factorio-server-manager:$TAG
lint:
BUILD +hadolint
BUILD +shellcheck-lint
test:
BUILD +go-test
BUILD +renovate-validate
###############################################################################
# Individual Targets
###############################################################################
go-test:
# renovate: datasource=docker depName=golang
ARG GOLANG_VERSION=1.18
FROM golang:$GOLANG_VERSION
WORKDIR /usr/src/app
COPY conf.json.example conf.json
COPY --dir src .
WORKDIR src
# Setup Tests to look for things in the right place...
ENV FSM_CONF ../../conf.json
ENV FSM_DIR ../
ENV FSM_MODPAKC_DIR dev_pack
RUN go test ./... -v -test.short
hadolint:
# renovate: datasource=docker depName=hadolint/hadolint versioning=docker
ARG HADOLINT_VERSION=2.12.0-alpine
FROM hadolint/hadolint:$HADOLINT_VERSION
WORKDIR /images
COPY .hadolint.yaml .
COPY docker/Dockerfile* .
RUN find . -name "Dockerfile*" -print | xargs -r -n1 hadolint
renovate-validate:
# renovate: datasource=docker depName=renovate/renovate versioning=docker
ARG RENOVATE_VERSION=38
FROM renovate/renovate:$RENOVATE_VERSION
WORKDIR /usr/src/app
COPY renovate.json .
RUN renovate-config-validator
shellcheck-lint:
# renovate: datasource=docker depName=koalaman/shellcheck-alpine versioning=docker
ARG SHELLCHECK_VERSION=v0.10.0
FROM koalaman/shellcheck-alpine:$SHELLCHECK_VERSION
WORKDIR /mnt
COPY . .
RUN find . -name "*.sh" -print | xargs -r -n1 shellcheck