Update .gitlab-ci.yml file

This commit is contained in:
Stefan H 2022-02-17 09:48:12 +01:00
parent 2b08f11c1e
commit a716d7473a
1 changed files with 8 additions and 3 deletions

View File

@ -19,6 +19,7 @@ stages: # List of stages for jobs, and their order of execution
build-job: # This job runs in the build stage, which runs first.
stage: build
script:
- echo "******** Start Build Docker Image ********"
- docker build -t php-apache-rsvg .
@ -26,6 +27,10 @@ build-job: # This job runs in the build stage, which runs first.
deploy-job: # This job runs in the deploy stage.
stage: deploy # It only runs when *both* jobs in the test stage complete successfully.
script:
- echo "Deploying application..."
- echo "Application successfully deployed."
before_script:
- echo "Login to Docker Hub"
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY
script:
- echo "Pushing Image to Docker Hub..."
- docker push "$CI_REGISTRY_IMAGE"
- echo "Push done"