-
Notifications
You must be signed in to change notification settings - Fork 2
/
bitbucket-pipelines.yml
53 lines (50 loc) · 2.14 KB
/
bitbucket-pipelines.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
image: heptacom/heptaconnect-pipeline:php74-latest
definitions:
services:
mysql:
image: mysql:5.7
variables:
MYSQL_DATABASE: 'heptaconnect_shopware'
MYSQL_ROOT_PASSWORD: 'root'
steps:
- step: &default-step
caches:
- composer
artifacts:
- .build/**
- vendor/**
- composer.lock
- step: &github-keyword-gate-step
<<: *default-step
name: Github Keyword Gate
script:
- 'test $(git --no-pager log --full-history "--grep=${GITHUB_GREP_DENY_PATTERN}" | wc -l) -eq 0'
- 'test $(git --no-pager log --full-history -S "${GITHUB_GREP_DENY_PATTERN}" --pickaxe-all --pickaxe-regex --oneline | wc -l) -eq 0'
after-script:
- 'test ${BITBUCKET_EXIT_CODE} -eq 0 || git --no-pager log --full-history "--grep=${GITHUB_GREP_DENY_PATTERN}"'
- 'test ${BITBUCKET_EXIT_CODE} -eq 0 || git --no-pager log --full-history -S "${GITHUB_GREP_DENY_PATTERN}" --pickaxe-all --pickaxe-regex --oneline'
- step: &github-mirror-branch
<<: *default-step
name: Mirror to Github
script:
- git fetch --unshallow origin
- git remote add github "git@github.com:HEPTACOM/${BITBUCKET_REPO_SLUG}.git"
- git push --force github ${BITBUCKET_BRANCH}
pipelines:
branches:
master:
- step: *github-keyword-gate-step
- step:
<<: *github-mirror-branch
trigger: manual
default:
- step:
<<: *default-step
image:
name: heptacom/heptaconnect-pipeline:php74-latest
run-as-user: 0
name: Install shopware runtime
services:
- mysql
script:
- DATABASE_URL=mysql://root:root@127.0.0.1:3306/heptaconnect_shopware make shopware-platform