Skip to content
Snippets Groups Projects
Commit e05bb97a authored by Matthieu Boileau's avatar Matthieu Boileau
Browse files

Update makefile and .gitlab-ci.yml

parent 6e1c39b4
No related merge requests found
stages:
- build
- test
- release
variables:
CONTAINER_TEST_IMAGE: boileaum/rosen:$CI_COMMIT_REF_NAME
CONTAINER_RELEASE_IMAGE: boileaum/rosen:latest
before_script:
- echo $DOCKERHUB_PASSWD | docker login -u boileaum --password-stdin
b:docker:
build_hello:
stage: build
tags:
- shell, docker
script:
- docker build --pull -t $CONTAINER_TEST_IMAGE -f ./docker/Dockerfile-rosen .
- docker push $CONTAINER_TEST_IMAGE
- make
t:helloworld:
test_hello:
stage: test
tags:
- shell, docker
script:
- docker pull $CONTAINER_TEST_IMAGE
- docker run $CONTAINER_TEST_IMAGE /bin/bash -c 'python test_helloworld.py'
t:rosen:
stage: test
tags:
- shell, docker
script:
- docker pull $CONTAINER_TEST_IMAGE
- docker run $CONTAINER_TEST_IMAGE /bin/bash -c 'pytest -v'
r:docker:
stage: release
tags:
- shell, docker
script:
- docker pull $CONTAINER_TEST_IMAGE
- docker tag $CONTAINER_TEST_IMAGE $CONTAINER_RELEASE_IMAGE
- docker push $CONTAINER_RELEASE_IMAGE
only:
- master
- make test
.PHONY: clean
all: helloworld
helloworld:
gcc helloworld.c -o helloworld.e
cc helloworld.c -o helloworld.e
test: helloworld
python test_helloworld.py
clean:
rm -rf *.o *.e *.so *.pyf *.pyc __pycache__
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment