-
Notifications
You must be signed in to change notification settings - Fork 59
/
docker-compose.yml
61 lines (56 loc) · 1.62 KB
/
docker-compose.yml
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
# syntax version.
version: "3"
# volumes.
volumes:
php-alpine-cache-v3.15:
php-alpine-cache-v3.14:
php-alpine-cache-v3.13:
php-alpine-cache-v3.12:
php-alpine-cache-v3.11:
php-alpine-cache-v3.10:
# services.
services:
# sandbox base image
sandbox:
# specify docker platform to run.
platform: ${DOCKER_PLATFORM}
# target image.
image: "codecasts/php-alpine:sandbox-v${ALPINE_VERSION}"
# enable tty.
tty: true
# build config.
build:
context: "sandbox"
args:
DOCKER_PLATFORM: ${DOCKER_PLATFORM}
ALPINE_VERSION: ${ALPINE_VERSION}
APK_MAINTAINER: ${APK_MAINTAINER}
APK_PACKAGER: ${APK_PACKAGER}
# declare volumes and mounting.
volumes:
- "./bin:/opt/php-alpine/bin"
- "./scripts/v${ALPINE_VERSION}:/home/sandbox/scripts"
- "./.abuild:/home/sandbox/.abuild"
- "./repo/v${ALPINE_VERSION}:/home/sandbox/packages"
- "php-alpine-cache-v${ALPINE_VERSION}:/var/cache/apk"
# sandbox for building on alpine edge.
starter-images:
platform: ${DOCKER_PLATFORM}
# target image.
image: "codecasts/php-alpine:alpine-v${ALPINE_VERSION}-php-${PHP_VERSION}"
build:
context: "images"
args:
ALPINE_VERSION: ${ALPINE_VERSION}
PHP_VERSION: ${PHP_VERSION}
# sandbox for building on alpine edge.
release-image:
platform: ${DOCKER_PLATFORM}
# target image.
image: "codecasts/php-alpine:alpine-v${ALPINE_VERSION}-php-${PHP_VERSION}"
build:
dockerfile: release/image/Dockerfile
context: "."
args:
ALPINE_VERSION: ${ALPINE_VERSION}
PHP_VERSION: ${PHP_VERSION}