-
Notifications
You must be signed in to change notification settings - Fork 5
/
.gitlab-ci.yml
50 lines (46 loc) · 1.21 KB
/
.gitlab-ci.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
variables:
GITHUB_REPO: $CI_PROJECT_NAME
GITHUB_GROUP: enix
PYTHONUNBUFFERED: "1"
ANSIBLE_FORCE_COLOR: "1"
PY_COLORS: '1'
molecule:
stage: test
services:
- docker:dind
variables:
DOCKER_BUILDKIT: 1
DOCKER_HOST: tcp://docker:2376
DOCKER_TLS_CERTDIR: "/certs"
DOCKER_TLS_VERIFY: 1
DOCKER_CERT_PATH: "$DOCKER_TLS_CERTDIR/client"
DOCKER_DRIVER: overlay2
image: docker:stable-dind
before_script:
- apk add --no-cache
python3 python3-dev py3-pip gcc git curl build-base
autoconf automake py3-cryptography linux-headers
musl-dev libffi-dev openssl-dev openssh rsync
- python3 -m pip install ansible molecule[docker] ansible-lint yamllint
- docker info
- python3 --version
- ansible --version
- ansible-lint --version
- yamllint --version
- molecule --version
script:
- molecule test --all -- -vv
tags:
- docker-dind
importgalaxy:
stage: deploy
image: registry.gitlab.com/lcaflc/ansiblecheck:debian-bullseye
only:
- main
- master
- tags
# when: on_success
before_script:
- ansible --version
script:
- ansible-galaxy role import ${GITHUB_GROUP} ${GITHUB_REPO} --token ${GALAXY_API_TOKEN}