From 64af5ef1a0ae281bdb2454aa1bb950f8e1d72857 Mon Sep 17 00:00:00 2001 From: "marcoemi.poleggi" <marco-emilio.poleggi@hesge.ch> Date: Thu, 24 Nov 2022 14:53:05 +0100 Subject: [PATCH] Update README.md --- README.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index eb6748a..ace16fd 100644 --- a/README.md +++ b/README.md @@ -58,8 +58,6 @@ Fork this project into your personal namespace and configure it (menu `Settings` Our GitLab instance comes with a shared Docker-based CI/CD *runner* (or executor). Generate your [SSH key pair](https://docs.gitlab.com/ee/ci/ssh_keys/) to interact with your VM instance. -(**[TO-DO]** :question: Do we also need to enable `Repository > Deploy keys` with the same public SSH key?) - Configure the CI/CD system as it follows (menu `Settings > CI/CD`): - In `General pipelines`: * [ ] `Public pipelines` @@ -89,7 +87,7 @@ stages: # Do here anything common to all jobs' scripts before_script: - - # install needed packages in this runner + - # install needed packages in this runner (Web servr, etc.) - # configure the git client on this runner - # set up SSH keys via ssh-agent - # launch the ssh-agent and feed it our key from var $SSH_PRIVATE_KEY @@ -99,6 +97,7 @@ before_script: unit_test1: stage: test script: + - # clone our repo locally - # check the app version number and exit != 0 if it's wrong deploy_prod: @@ -114,6 +113,8 @@ deploy_prod: ``` The "deploy_prod" stage shall run only if we're pushing to the main branch. +:bulb: If you followed the [Ansible exercise](https://gitedu.hesge.ch/lsds/teaching/bachelor/cloud-and-deployment/lab-ansible), you're encouraged to integrate it into the deploy stage. Otherwise, a simple remote copy via `scp` or `rsync` suffices. + ### Task #3: test operation ### **Goal:** Test the pipeline by pushing a commit to the main branch. -- GitLab