diff --git a/.drone.yml b/.drone.yml index 16ac98d..d824b37 100644 --- a/.drone.yml +++ b/.drone.yml @@ -2,13 +2,20 @@ kind: pipeline type: docker name: DAFLPipeline +trigger: + event: + - push + steps: +# build CONTAINER for app-build on cirrusci IMAGE - name: app-build image: cirrusci/flutter:stable commands: - flutter doctor - - flutter build - + - cd ./Sources/dafl_project_flutter/ + - flutter build apk + +# build CONTAINER for sonar on cirrusci IMAGE - name: code-analysis image: cirrusci/flutter:stable environment: @@ -24,4 +31,15 @@ steps: - export PATH=$SONAR_SCANNER_HOME/bin:$PATH - export SONAR_SCANNER_OPTS="-server" - sonar-scanner -D sonar.projectKey=DAFLMusic -D sonar.sources=. -D sonar.host.url=https://codefirst.iut.uca.fr/sonar - depends_on: [ app-build ] \ No newline at end of file + depends_on: [ app-build ] + +# container deployment +- name: deploy-container + image: hub.codefirst.iut.uca.fr/thomas.bellembois/codefirst-dockerproxy-clientdrone:latest + settings: + dockerfile: ./Sources/api_redirect/Dockerfile + environment: + IMAGENAME: httpd:2.4 + CONTAINERNAME: api-redirect + COMMAND: create + OVERWRITE: true \ No newline at end of file diff --git a/Sources/api_redirect/Dockerfile b/Sources/api_redirect/Dockerfile new file mode 100644 index 0000000..bde780c --- /dev/null +++ b/Sources/api_redirect/Dockerfile @@ -0,0 +1,2 @@ +FROM httpd:2.4 +COPY ./public-html/ /usr/local/apache2/htdocs/ \ No newline at end of file diff --git a/Sources/api_redirect/public-html/index.html b/Sources/api_redirect/public-html/index.html new file mode 100644 index 0000000..4f1af38 --- /dev/null +++ b/Sources/api_redirect/public-html/index.html @@ -0,0 +1 @@ +Hello world Dafl ! \ No newline at end of file