A lesson is completed when you tick it, when you watch its video to the end or when you score 80% on its quiz. The certificate is issued online after the final assessment, from a score of 32 out of 40.
Lesson 37, module 10: From preview to production Branches, staging and going live Claire wants to see the cuvées page online. Malik has pushed. Is it live?
Branch, push, staging, acceptance testing, merge, production. [Diagram: From branch to production] 1. Branch 2. Push 3. Staging 4. Acceptance testing 5. Merge 6. Production Pushing isn't deploying. Production only goes out when a person asks for it. Pushing isn't deploying. One branch per task Never force push or rewrite history "protected branch": you need a branch Staging goes out when the person wants to see the result online. Request: The task's branch has been pushed. Deploy staging with the repository's recipe, then recheck the staging address and tell me the deployed commit. Response: The review passes, the launch goes to the staging target, the output shows in the Terminal. The log keeps the commit and "by an agent". The rechecked address responds. Before production, five questions. Only one is yours: did you ask for it? [Diagram: The review before production] 1. Did a person ask for this release? 2. Is the working tree clean and everything pushed? 3. Is the code merged into the target's branch? 4. Is continuous integration not red? 5. Does the company policy leave this action open? Yes to all: The launch goes out, the log keeps the commit, and the address is rechecked afterwards. The log says what's live. A fix starts from there. A target's first successful launch The commit and the previous commit A rollback replays a launch The more an action touches production, the more it needs a person. [Diagram: Delivery actions] Vertically, risk; horizontally, frequency. Releasing a redesign Rollback Staging a task Preferred: Urgent fix in production The more an action touches production, the more it needs a person and a trace. In the exercise, you take the cuvées page from branch to production. Your turn: The cuvées page, from branch to production The written course, the corrected exercise and the quiz are below the video.
Lesson 37 of 48 · module 10, from preview to production
Branches, staging and release to production
Every task has its own branch; pushing the branch puts nothing live. Staging is deployed by the repository’s recipe, production only at a person’s request, after a strict check. You learn to push, deploy, read the deployment log, start a hotfix from the live commit, and roll back.
21 min of reading
1 min 58 of video
7 diagrams
4 demandes to copy
3 exemples pratiques
4 exercices answerss
5 questions
1 ressource
By the end of this lesson, you will know how to
Work on one branch per task, push and open a merge request without touching main
Deploy to staging and then, on request, to production, passing the Nexus check
Read the deployment log to find out what is live, and start a fix from that commit
What’s covered
One branch per task
Staging
Production, on request
The log, the fix and the rollback
3 worked examples, followed from start to finish
Exercise with answers · The cuvées page, from branch to production
3 practice exercises, from guided to demanding cases
The quiz
Key points
One branch per task, commits prefixed [tache <id>], never a force push; “protected branch” means “you need a branch”.
Pushing is not deploying: staging is deployed afterwards, using the repository’s recipe.
Production is only released at a person’s request, after a strict check: clean tree, everything pushed, merged, continuous integration not red.
The deployment log tells you what is live; a fix starts from that commit, not from main.
A rollback replays a launch: the code goes back, the database does not.
Wednesday, 4pm. Malik has finished the cuvées page and pushed his branch to GitLab. Claire writes to him: “Great, I’ll take a look on the site.” She sees nothing, and that’s normal. Pushing is not deploying. A pushed branch is a copy of the work on the forge; nothing is live until a deployment has run. This lesson sorts out the four actions everyone confuses: pushing, deploying to staging, merging and releasing to production.
From branch to production
1Branch
One per task, never main; commits prefixed [tache <id>].
2Push
The branch goes to GitLab or GitHub: nothing is live yet.
3Pre-production
Deployed by the repository’s recipe, closed to search engines.
4Acceptance testing
Findings resolved, checked and approved by the person.
5Merge
Merge request reviewed, code merged, continuous integration not red.
6Production
At the person’s request, strict review, address checked afterwards.
Pushing is not deploying. Production is only released when a person requests it.
One branch per task
Every task has its own branch, opened with “Work on it”; nobody works on the main branch, which is protected on the forge. A “protected branch” or “not allowed to push” refusal does not point to a permissions problem: it means “you need a branch”. When the session is tied to a task, every commit message starts with [tache <id>]. Two things are forbidden: force push and rewriting history. The branch graph and modified files can still be viewed from Nexus.
Commit and push the task branchTerminal
# vérifier que la branche courante n'est pas la principale (main ou master)
git branch --show-current
# si c'est la principale : créer la branche de la tâche avant tout commit
git switch -c [nom-court-de-la-tache]
# commiter les seuls fichiers de la tâche, message préfixé par la tâche
git add [fichiers de la tâche]
git commit -m "[tache [id]] Page Domaine et cuvées : six fiches, une adresse par cuvée"
# pousser la branche, sans jamais forcer
git push -u origin HEAD:refs/heads/[nom-court-de-la-tache]
Standard git commands. The [tache <id>] prefix and the push to refs/heads/<branche> are the conventions Nexus sets in each project’s folder (as recorded on 15 November 2026).
The forge (GitLab or GitHub) responds to the push with a link to open a merge request. It is reviewed before being merged, according to the team’s rules: this is where Claire or another developer sees the diff. Repository access set up by Nexus follows the project assignments and is removed when a member leaves; access managed directly on the forge keeps its own management.
Staging
Deployment relies on a recipe saved in the repository, .nexus/deploiement.json, which names the targets (staging, production) and how to deploy each one; it can use credentials from the vault. The project must be configured for its hosting before the first release. Staging is deployed from Nexus (the project’s Repository tab, or on a merge made in Nexus) or by the session’s agent, after pushing. A properly configured staging environment is closed to search engines: Google must not index a site under acceptance testing.
Deploy staging from the screen
Open the wine merchant’s project in the desktop app, then the Repository tab.
Check the branch and the last commit pushed.
Choose the recipe’s staging target.
Confirm: the output appears in the project Terminal, and the address is rechecked at the end.
Send the staging address to the person doing the acceptance testing. The tab label may vary slightly depending on your version of Nexus.
Have the agent deploy to staging
The branch for the task “[task title]” has been pushed. Check that the tree is clean and everything is pushed, then deploy the staging target using the repository’s deployment recipe. After deployment, open the staging address in the preview on desktop and mobile and report back. Tell me the deployed commit. Don’t touch production.
Roughly what you should get
What to expect: the check passed (clean tree, branch pushed), the run on the staging target, the output in the Terminal, the deployed commit, then a report on the page at two formats. If a run on the same target is already in progress, Nexus refuses and the agent says so.
Production, on request
An agent never puts anything into production on its own initiative: without a request, it says the work is ready. When the person asks for it (“put it in prod”), the agent launches the production target, and Nexus applies a stricter review than for pre-production: clean tree, everything pushed, code merged, continuous integration not red. A refusal says what to fix. Company policy can block this action: in that case it is a flat refusal, to be taken to an administrator, never worked around.
The check before production
1Has a person asked for this production release?
No Run nothing: say it is ready, and wait for the request.
2Is the working tree clean and is everything pushed?
No Commit or discard the changes, push, then try again.
3Is the code merged into the target’s branch?
No Open or complete the merge request.
4Is continuous integration not red?
No Fix the failure before any run.
5Does company policy leave this action open?
No The refusal is a rule: ask an administrator.
Yes to allThe run starts, the log keeps the commit, and the address is checked afterwards.
Nexus applies the same check to an agent as to a human, and a stricter one for production.
The production release request, by Claire
Acceptance testing of the wine merchant’s site is approved and the merge request has been merged. Release to production using the recipe’s production target. Before running it, tell me the commit that will go out and the one live today. Afterwards, check the site address, open the home page, the cuvées and the contact page in the preview on desktop and mobile, and give me the report.
Roughly what you should get
What to expect: both commits stated (the one going out, the one it replaces), the strict check passed, the run, the address rechecked, then the preview report on the three pages. The log records the run as “by an agent”, at Claire’s request.
Claire asks; Malik does not decide alone: release to production remains a step taken by the person responsible for the project.
The log, the fix and the rollback
The deployment log shows, from newest to oldest, who put which commit live, replacing which commit, on which target, with which credentials, and how it ended: exit code and address check (OK, ECHEC, NON_DEMANDEE, ABANDONNE). A target’s most recent successful run tells you what is live: read it before any intervention. A fix starts from that commit, not from main, which may carry unreleased work. A run left unfinished for two hours is closed as “abandoned” by Nexus.
Read what is in production, via the APITerminal
# le dernier lancement de production du projet (clé en lecture seule suffisante)
curl -s -H "Authorization: Bearer $NEXUS_CLE" \
"https://api.nexus-engine.eu/api/v1/projects/[identifiant du projet]/deploiements?environnement=PRODUCTION&limit=1"
Route taken from the API documentation on 15 November 2026. It lets you monitor; no route launches a deployment.An urgent fix, on a Saturday
9 h 10Alert
Sandrine: the contact form returns an error.
9 h 15What is live
The log gives the production commit.
9 h 40Hotfix branch
Started from that commit, tested, pushed, in staging.
10 h 05Production requested
By Claire, with the reason for urgency.
10 h 10Address rechecked
The form responds and the failure thread closes.
Release actions
fortRiskfaible
Releasing a redesign to production
On request, after acceptance testing is signed off and the merge is done. Strict review.
Urgent hotfix in production
Starts from the live commit, with a reason for urgency that notifies the team.
Rollback
Replay a previous successful launch, and tell the client.
Staging for a task
After each branch is pushed, so the person can see the result.
rareFrequencyfrequent
The more an action affects production, the more it needs a person and a record.
Mistakes to avoid
Announcing “it’s live” after pushing the branch.
Pushing puts the code on the forge, not on a server: the person opens the address and sees nothing, or sees the old version.
Push, then deploy staging, check the address and send the address with the deployed commit.
Letting the agent release to production because acceptance testing is approved.
Approved acceptance testing is not a request to release to production: the date, the time and when to tell the client belong to the person.
The agent says “ready”; the person responsible requests production, with the strict check.
Starting from main for an urgent fix.
Main may carry features that are merged but not released: the fix would put them live without acceptance testing.
Read the production commit in the log and create the fix branch from it.
Force the push to get round a refusal from the forge.
A force push rewrites shared history and can wipe out a colleague’s work; a “protected branch” refusal means you need a branch.
Create a branch, push it, open a merge request; never force push or rewrite history.
3 SME situations followed from start to finish: the prompts exactly as they were written, the model answer to aim for, and what was checked before sending.
Example 1
A first delivery for a trading SME
Antoine is a developer at an eight-person web agency in Bordeaux. He is delivering the site of a 25-employee building materials trading SME in Libourne. It is the first go-live: the deployment recipe does not yet exist in the repository.
The first release
1Acceptance testing proposed
Two targets, credentials named.
2Acceptance testing passed
Staging closed to search engines.
3Pre-production
First run in the log.
4Production
On request, a week later.
Request 1
The repository does not have a deployment recipe yet. Read the project sheet and the vault credentials (staging and production at the host). Propose the .nexus/deploiement.json recipe with two targets, staging and production, and tell me which credentials it will use. Don’t write or deploy anything until I agree.
Model answer
What to expect: a proposed recipe with two targets, the command for each, the vault credential each one uses (named by its label, with no secret), and the question of closing staging to search engines.
Antoine has the agent close staging to search engines, then accepts.
Request 2
Acceptance testing passed. Commit it to the task branch, push, then deploy pre-production and check the address. No production.
Model answer
What to expect: the recipe committed and pushed, the first staging run in the log with its commit, the address rechecked (OK).
Production goes out a week later, at the request of the managing director, passed on by the project manager.
What was checked before sending
The recipe: proposed, reviewed and accepted before being written.
Credentials: named by their label, no secrets in the recipe.
Production: requested by a person, a week later.
Order of magnitude: a release procedure written once and replayed for every version, instead of a manual FTP transfer for every release.
Example 2
A fix on a Saturday morning
Lina is a freelance developer in Talence. One Saturday at 9am, the manager of a 14-employee restaurant on the banks of the Garonne calls her: the booking module has been showing an error since the previous evening.
Saturday morning at the restaurant
9 hCall
Bookings failing.
9 h 10Record
The live commit identified.
9 h 45Pre-production
Hotfix tested, journey run.
10 hProduction
With an urgency reason, address rechecked.
Request 1
Read the deployment log for the restaurant’s project: which commit is in production, since when, and which commit did it replace? Don’t change anything.
Model answer
What to expect: the last successful run on the production target (commit, date, author), the previous commit, and the note that the main branch has two more commits, not yet released.
Lina starts from the live commit, not from main.
Request 2
Create a hotfix branch from the commit in production. Find the cause of the booking error, fix it, run the tests with the Nexus tool, push, deploy to staging and run the booking journey in the preview without confirming a real booking.
Model answer
What to expect: the cause (for example a date format rejected by the booking service), the fix, the tests, staging, and the journey run through to the summary.
Lina requests production herself, with the reason for urgency “bookings failing since Friday evening”.
What was checked before sending
The starting point: the live commit, read from the log.
The proof: the journey played through in staging.
The record: the reason for urgency, which notifies administrators and assignees.
Order of magnitude: one hour between the call and the fix going live, without putting two untested features live.
Example 3
A production release refused by the review
Quentin is a project manager at a four-person web studio in Bègles. At 6pm on a Thursday, just before an event, he asks for the website of a Bordeaux cultural association with 3 employees to be put into production.
With or without the review
Without review
A dirty tree goes live
An unreviewed fix in production
Nobody knows which commit is live
With the check
The refusal tells you what to fix
Code merged and reviewed
The log keeps the commit
Request 1
Release the association’s site to production using the production target. Tell me beforehand which commit is going out.
Model answer
What to expect: the check refuses the run and says what to fix: two modified files not committed and a branch not merged. No run is started.
Quentin discovers that a last-minute fix had been left lying on the developer’s machine.
Request 2
List the modified, uncommitted files and say which task they belong to. Don’t commit or delete anything: I’ll check with the developer.
Model answer
What to expect: the two files, the likely task, and the note that this task’s branch has not been merged.
The developer commits, has it reviewed and merged. Production goes out at 6:40pm.
What was checked before sending
The check: the refusal read and understood, not got round.
The developer’s work: neither committed nor deleted by the agent.
Production: rerun after the merge, still on request.
Order of magnitude: forty minutes’ delay, instead of putting unreviewed code live the day before an event.
Malik has finished the cuvées page on his branch, not yet pushed. Claire wants to see it in staging this evening; Sandrine will test it on Thursday; Claire will decide on the production release, planned for Tuesday 24 November at 7am. At 7am that Tuesday, acceptance testing is approved, but the merge request is not yet merged and continuous integration is orange. Write out the next actions, who does them, and the requests to the agent.
Write Malik’s git commands up to the push.
Write the request to deploy to staging.
Say what the production check will refuse on Tuesday at 7am, and why.
Write the request to release to production, and say who writes it.
See the answers
Malik’s requestsTerminal
git branch --show-current # la branche de la tâche, pas main
git status # seuls les fichiers de la tâche
git add [fichiers de la page des cuvées]
git commit -m "[tache [id]] Page Domaine et cuvées"
git push -u origin HEAD:refs/heads/[branche de la tâche]
Staging, this evening
The branch for the task “Estate and cuvées page” has been pushed. Deploy the staging target using the repository’s recipe, check the address, open /cuvees and one cuvée page in the preview on desktop and mobile, and tell me the deployed commit. No production.
Roughly what you should get
What to expect: the staging run, the commit, the address rechecked and two findings. Malik sends the address to Claire.
On Tuesday at 7am, the production check will refuse: the code is not merged. Orange continuous integration (in progress) is not red; if it turns red, it blocks too. Malik has the merge request reviewed and merged, waits for continuous integration to go green, and tells Claire it is ready. He doesn’t run anything himself.
Production, requested by Claire
Acceptance testing of the cuvées page is approved and the code is merged. Release to production. Before you do, tell me the commit going out and the one currently live. Afterwards, check the site address and give me the preview report for /cuvees on desktop and mobile.
Roughly what you should get
What to expect: both commits stated, the strict check passed, the run, the address rechecked, the preview report. The log records the run and the commit it replaces.
Who does what: Malik pushes, requests pre-production and gets the merge done. Sandrine runs acceptance testing. Claire signs off the findings and requests production. The agent launches every deployment, but never production unless Claire asks for it.
Practise
Three more exercises, from the most guided to the most demanding. The material is provided in full: copy it into your tool, then check your work against the criteria before opening the answers.
Level 1 · guided10 min
Push, deploy, merge, release to production
For each sentence, say which action it refers to (pushing, deploying to staging, merging, releasing to production) and who decides it.
The material to work on
1. “My branch is on GitLab.”
2. “Sandrine can view the page at the acceptance address.”
3. “The merge request has been reviewed and accepted.”
4. “The merchant’s site shows the new page at its public address.”
Check your work
1: push, decided by the developer.
2: deploy to staging, when the person wants to see the result.
3: merge, following the team’s rules, after review.
4: release to production, at the request of the person responsible.
See the answers
Sentence
Action
Who decides
1
Push
Malik
2
Deploy to staging
Malik or the agent, when Claire wants to see it
3
Merge
The reviewer, according to the team’s rules
4
Release to production
Claire, who requests it
The first action, as a commandTerminal
git push -u origin HEAD:refs/heads/[branche de la tâche]
Level 2 · independent15 min
Read the deployment log
Here is an extract from the deployment log for the wine merchant’s project. Say what is live in production and in pre-production, what went wrong, and where a fix will start from.
The material to work on
Most recent first:
- Tuesday 24 November, 7.02am · production · commit 7e41c2a (replaces 3b9d0f1) · by an agent, requested by Claire · exit 0 · address rechecked: OK
- Monday 23 November, 6.30pm · staging · commit 7e41c2a · by an agent · exit 0 · address rechecked: OK
- Monday 23 November, 5.55pm · staging · commit 5a2e8c4 · by Malik · exit 1 · address rechecked: FAILED
- Monday 16 November, 11.15am · production · commit 3b9d0f1 · by Malik · exit 0 · address rechecked: OK
Check your work
Production: 7e41c2a, since Tuesday 24 November, 7:02am.
Staging: 7e41c2a, as the 5:55pm run failed.
A production fix starts from 7e41c2a.
A rollback would replay the 3b9d0f1 launch.
See the answers
In production: 7e41c2a, released on Tuesday 24 November at 7:02am at Claire’s request, replacing 3b9d0f1. In staging: also 7e41c2a; Monday’s 5:55pm run (5a2e8c4) failed, with exit code 1 and the address check failing, and was replaced at 6:30pm. A fix starts from 7e41c2a. A rollback would replay the run of Monday 16 November (3b9d0f1).
Check via the agent
Read the deployment log for the wine merchant’s project and tell me the live commit on each target, and the latest failure with its cause if the output gives it. Don’t run anything.
Roughly what you should get
What to expect: 7e41c2a on both targets, and Monday’s 5.55pm failure with the end of its output.
Level 3 · demanding case35 min
A production release that goes wrong
Tuesday 24 November, 7:15am, a quarter of an hour after the production release, Sandrine writes that the cuvée pages no longer show prices and that a tasting order has been recorded at the wrong price. Say, in order, what the team does and who does each action, and write the requests to the agent. Say what the rollback will not fix.
The material to work on
Log: production 7e41c2a since Tuesday 7.02am (replaces 3b9d0f1).
Version 7e41c2a added a price field to the cuvée database and migrated the old prices.
Main: 7e41c2a, nothing more.
Production database backup: Monday 11pm.
Check your work
Claire decides between a rollback and a hotfix, and tells Sandrine.
The rollback replays the 3b9d0f1 run, at Claire’s request.
You say the database does not go back: the price migration stays, and the earlier code may no longer be able to read it.
The order at the wrong price is handled by a person, with Sandrine.
A fix starts from 7e41c2a, in pre-production first.
See the answers
First action: read, don’t act. Version 7e41c2a migrated the prices in the database: a rollback would put the old code back against an already migrated database, which could break in other ways. So Claire chooses a quick fix rather than a rollback, and writes to Sandrine to suspend tasting bookings for an hour.
Understand before you touch
Read-only on the merchant’s production: read the log, then check in the database the prices of the six wines (old field and new field) and the latest tasting order. Tell me why the product pages no longer show the prices. Don’t change anything, neither code nor database.
Roughly what you should get
What to expect: the cause (for example the new field empty for two wines and a page that only reads the new field), the state of the prices, and the order placed at the wrong price identified.
The fix
Create a hotfix branch from 7e41c2a. Fix the price display so that it falls back to the old field when the new one is empty, run the tests with the Nexus tool, push, deploy to staging and check the six product pages in the preview. Don’t fix the database yourself: prepare the list of prices to correct so that Sandrine can confirm them.
Roughly what you should get
What to expect: the branch, the fix, the tests, staging checked, then the list of prices to confirm. Production waits for Claire’s request.
Claire requests production with the urgency reason “wine prices missing”. Sandrine confirms the prices; the database is corrected with her agreement. The order placed at the wrong price is handled between Sandrine and her customer: that is not an agent’s job. Monday’s 11pm backup remains the last resort, because it would also wipe Tuesday morning’s orders.
Every request to the project agent written in the course, including model answers, worked examples and practice exercises, sorted by module and lesson, with filters to find the right one.
For each lesson, the main exercise and the three graded practice exercises with their materials, to do on paper or alongside Nexus; all model answers are gathered at the end.
The course’s worked examples, from the first project to production: the situation, the request as it was written, the agent’s typical answer and what was checked before approving.
All the lessons in a single PDF: objectives, written course with its diagrams, tables and requests, common mistakes, exercise and key takeaways. The practice exercises and answers are in the workbook, the examples in the collection.
Your notes stay on this device; they are not sent anywhere.
A question for the tutor
A result that doesn’t match the model answer, a prompt that gets you nowhere, a case specific to your business: write to us with your prompt and the response you got. A Bonbay Académie trainer replies within 24 working hours, on your case.