Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
## Goal
<!-- What does this PR accomplish? 1 sentence. -->

## Changes
-

## Testing
<!-- How did you verify it? -->

## Checklist
- [ ] Title is a clear sentence (≤ 70 chars)
- [ ] Commits are signed (`git log --show-signature`)
- [ ] `submissions/labN.md` updated
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -61,3 +61,5 @@ Thumbs.db
# *.sbom.cdx.json, zap-*.html/json, trivy-*.txt (Lab 9 scan evidence)
# flake.nix, flake.lock (Lab 11)
# wasm/main.go, spin.toml, go.sum (Lab 12)
data/
app/data/
1 change: 1 addition & 0 deletions evidence/lab2/01-rev-parse.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
0ecd6ba6ff0e80f8f23f509c122d0247da0f5584
1 change: 1 addition & 0 deletions evidence/lab2/02-type.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
commit
14 changes: 14 additions & 0 deletions evidence/lab2/03-commit.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
tree db88ba097f711cb5246801d5d4aac3b4792e4e7e
parent 9f41b7deb32343a831b5e47c61533fbc7c0ce67d
author Elvira <239804565+HNS2112@users.noreply.github.com> 1785785467 +0300
committer Elvira <239804565+HNS2112@users.noreply.github.com> 1785785467 +0300
gpgsig -----BEGIN SSH SIGNATURE-----
U1NIU0lHAAAAAQAAADMAAAALc3NoLWVkMjU1MTkAAAAgmWbLJSeWlD1Vuj7EC1J04q9jqj
ZyCXUjnh3hTPKxQSYAAAADZ2l0AAAAAAAAAAZzaGE1MTIAAABTAAAAC3NzaC1lZDI1NTE5
AAAAQIrYi8c4UDJc+sld4lU7nqv/4/mC/213oU4fb4EMK+lFtN5a17TM5FwYfRXgVi5NLq
5pwGh37MiPy6pqg9mCMwM=
-----END SSH SIGNATURE-----

docs: add PR template; ignore runtime data dir

Signed-off-by: Elvira <239804565+HNS2112@users.noreply.github.com>
6 changes: 6 additions & 0 deletions evidence/lab2/04-tree.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
040000 tree d0f15a494317a8a43f617b9d4784429b9c5167ab .github
100644 blob 966b15200a257d9978e6fde44ede0423c0224c7b .gitignore
100644 blob d10c04c6e7e0014f4fe883599c11747c15012d4e README.md
040000 tree 7d0898a908e274ea809722844cdbd836f3b1c05a app
040000 tree f4f047dd07b128eda5f899dfdaaf193f0291eaa2 labs
040000 tree c0ac2d55cf4335df659b347df3d19d0594a06b6c lectures
65 changes: 65 additions & 0 deletions evidence/lab2/05-blob.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# ⚠️ KEEP THIS FILE MINIMAL.
#
# This .gitignore is inherited by every student fork. Anything listed here
# is something a student CANNOT `git add` without `-f`. So this file must
# ONLY contain:
# (a) instructor-only paths (refs/), and
# (b) machine-generated junk that NOBODY should ever commit.
#
# Do NOT add lab DELIVERABLES here (scan reports, SBOMs, go.sum, k8s
# manifests, CI workflows, Dockerfiles, playbooks, dashboards, …). Students
# are told to commit those in their submission PRs — ignoring them upstream
# silently breaks the lab. When in doubt, leave it OUT of this file.

# ── Instructor-only ─────────────────────────────────────────────
# Reference submissions (dry-run worked examples). Never pushed upstream;
# students never see these. This is the one path that is intentionally hidden.
refs/

# ── Machine-generated junk (no one commits these) ───────────────
# Compiled binaries / local runtime state
app/quicknotes
app/data/
/quicknotes
*.exe

# Vagrant runtime state (Lab 5) — the Vagrantfile IS committed; .vagrant/ is not
.vagrant/

# Nix build symlinks (Lab 11) — flake.nix + flake.lock ARE committed; result is not
result
result-*

# Terraform state — MUST never be committed (can contain secrets)
*.tfstate
*.tfstate.backup
.terraform/

# Python virtualenvs / caches
.venv/
__pycache__/
*.pyc

# Editor / IDE
.vscode/
.idea/
*.swp

# OS noise
.DS_Store
Thumbs.db

# Local agent config (not part of the course)
.claude/

# NOTE: deliberately NOT ignored, because students commit them as lab evidence:
# submissions/labN.md (lab reports)
# .github/workflows/*.yml (Lab 3 CI)
# Dockerfile, compose.yaml (Lab 6)
# ansible/ (Lab 7)
# monitoring/ (Lab 8)
# *.sbom.cdx.json, zap-*.html/json, trivy-*.txt (Lab 9 scan evidence)
# flake.nix, flake.lock (Lab 11)
# wasm/main.go, spin.toml, go.sum (Lab 12)
data/
app/data/
28 changes: 28 additions & 0 deletions evidence/lab2/06-git-dir.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
$ ls -la .git/
итого 52
drwxrwxr-x 7 hns hns 4096 авг 4 19:34 .
drwxrwxr-x 8 hns hns 4096 авг 4 19:36 ..
-rw-rw-r-- 1 hns hns 403 авг 4 19:34 config
-rw-rw-r-- 1 hns hns 73 авг 4 19:34 description
-rw-rw-r-- 1 hns hns 588 авг 4 19:34 FETCH_HEAD
-rw-rw-r-- 1 hns hns 21 авг 4 19:34 HEAD
drwxrwxr-x 2 hns hns 4096 авг 4 19:34 hooks
-rw-rw-r-- 1 hns hns 3183 авг 4 19:34 index
drwxrwxr-x 2 hns hns 4096 авг 4 19:34 info
drwxrwxr-x 3 hns hns 4096 авг 4 19:34 logs
drwxrwxr-x 4 hns hns 4096 авг 4 19:34 objects
-rw-rw-r-- 1 hns hns 573 авг 4 19:34 packed-refs
drwxrwxr-x 5 hns hns 4096 авг 4 19:34 refs

$ cat .git/HEAD
ref: refs/heads/main

$ ls .git/refs/heads/
main

$ ls .git/objects/ | head
info
pack

$ find .git/objects -type f | wc -l
3
3 changes: 3 additions & 0 deletions evidence/lab2/07-before-reset.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
1fa1ee0 wip(lab2): more progress
544a3cd wip(lab2): start
0ecd6ba docs: add PR template; ignore runtime data dir
22 changes: 22 additions & 0 deletions evidence/lab2/08-after-reset.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
$ git status
Текущая ветка: main
Эта ветка соответствует «origin/main».

Неотслеживаемые файлы:
(используйте «git add <файл>...», чтобы добавить в то, что будет включено в коммит)
evidence/

индекс пуст, но есть неотслеживаемые файлы
(используйте «git add», чтобы проиндексировать их)

$ git log --oneline -3
0ecd6ba docs: add PR template; ignore runtime data dir
9f41b7d docs(lab7): make seed.json shipping explicit; require bonus artifacts, not logs
8de962e docs(lab11): fix nixpkgs pin vs go.mod collision; add network fallback pitfalls

$ git reflog
0ecd6ba HEAD@{0}: reset: moving to HEAD~2
1fa1ee0 HEAD@{1}: commit: wip(lab2): more progress
544a3cd HEAD@{2}: commit: wip(lab2): start
0ecd6ba HEAD@{3}: checkout: moving from main to main
0ecd6ba HEAD@{4}: clone: from github.com:HNS2112/DevOps-Intro.git
12 changes: 12 additions & 0 deletions evidence/lab2/09-recovery.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
Указатель HEAD сейчас на коммите 1fa1ee0 wip(lab2): more progress
$ git log --oneline -3
1fa1ee0 wip(lab2): more progress
544a3cd wip(lab2): start
0ecd6ba docs: add PR template; ignore runtime data dir

$ git status --short
?? evidence/

$ cat submissions/lab2.md
important work
more important work
6 changes: 6 additions & 0 deletions evidence/lab2/10-tag-type.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
$ git tag -l --format="%(refname:short) %(objecttype) %(*objecttype)"
v0.0.1 tag commit
v0.1.0-lab2-HNS2112 tag commit

$ git cat-file -t v0.1.0-lab2-HNS2112
tag
7 changes: 7 additions & 0 deletions evidence/lab2/11-tag-verify.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Good "git" signature for 239804565+HNS2112@users.noreply.github.com with ED25519 key SHA256:10QjC3lakxoG0ObZMeXhw0fBga6g+mk9UyhPWJNGmC0
object 0ecd6ba6ff0e80f8f23f509c122d0247da0f5584
type commit
tag v0.1.0-lab2-HNS2112
tagger HNS <239804565+HNS2112@users.noreply.github.com> 1785861815 +0300

Lab 2 milestone — version control deep dive
6 changes: 6 additions & 0 deletions evidence/lab2/12-protected-push.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
remote: error: GH006: Protected branch update failed for refs/heads/main.
remote:
remote: - Changes must be made through a pull request.
To github.com:HNS2112/DevOps-Intro.git
! [remote rejected] main -> main (protected branch hook declined)
error: не удалось отправить некоторые ссылки в «github.com:HNS2112/DevOps-Intro.git»
5 changes: 5 additions & 0 deletions evidence/lab2/13-before-rebase.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
* 1fa1ee0 wip(lab2): more progress
* 544a3cd wip(lab2): start
* 0ecd6ba docs: add PR template; ignore runtime data dir
* 9f41b7d docs(lab7): make seed.json shipping explicit; require bonus artifacts, not logs
* 8de962e docs(lab11): fix nixpkgs pin vs go.mod collision; add network fallback pitfalls
11 changes: 11 additions & 0 deletions evidence/lab2/14-after-rebase.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
* 1d91a02 wip(lab2): more progress
* 7607087 wip(lab2): start
* 8768460 docs: upstream moved while you worked
* 0ecd6ba docs: add PR template; ignore runtime data dir
* 9f41b7d docs(lab7): make seed.json shipping explicit; require bonus artifacts, not logs

$ git log --format="%h %G? %s" -4
1d91a02 G wip(lab2): more progress
7607087 G wip(lab2): start
8768460 G docs: upstream moved while you worked
0ecd6ba U docs: add PR template; ignore runtime data dir
1 change: 1 addition & 0 deletions evidence/lab2/15-protection-restored.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"admins":true,"linear":true,"pr":1,"signatures":true}
22 changes: 22 additions & 0 deletions evidence/lab2/16-bisect-run.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
running 'sh' '-c' 'cd app && go test ./... && go build ./...'
--- FAIL: TestStore_PersistsAcrossReload (0.00s)
store_test.go:78: nextID not restored: got 1, want 2
FAIL
FAIL quicknotes 0.003s
FAIL
Бинарный поиск: 0 редакций осталось проверить после этой (примерно 0 шагов)
[cb89bb9ee2ee5010b166061447eaca3ae0da2378] docs(store): comment the load() decode step
running 'sh' '-c' 'cd app && go test ./... && go build ./...'
ok quicknotes 0.004s
f285ede8611e55ac0a7d01100891c0cc775e0709 is the first bad commit
commit f285ede8611e55ac0a7d01100891c0cc775e0709
Author: Dmitrii Creed <creeed22@gmail.com>
Date: Fri Jun 5 13:36:56 2026 +0400

refactor(store): simplify nextID restoration in load()

Signed-off-by: Dmitrii Creed <creeed22@gmail.com>

app/store.go | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
bisect found first bad commit
12 changes: 12 additions & 0 deletions evidence/lab2/17-bisect-log.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
git bisect start
# status: waiting for both good and bad commits
# bad: [f0c9243b7c80ebb930a1ce7048a1d65b4c2ac493] docs(app): mention go test invocation
git bisect bad f0c9243b7c80ebb930a1ce7048a1d65b4c2ac493
# status: waiting for good commit(s), bad commit known
# good: [0ec87b808ae6a257a98ecea4a3c8d38a7f2c5ac7] chore(app): document versioning scheme (bisect fixture baseline)
git bisect good 0ec87b808ae6a257a98ecea4a3c8d38a7f2c5ac7
# bad: [f285ede8611e55ac0a7d01100891c0cc775e0709] refactor(store): simplify nextID restoration in load()
git bisect bad f285ede8611e55ac0a7d01100891c0cc775e0709
# good: [cb89bb9ee2ee5010b166061447eaca3ae0da2378] docs(store): comment the load() decode step
git bisect good cb89bb9ee2ee5010b166061447eaca3ae0da2378
# first bad commit: [f285ede8611e55ac0a7d01100891c0cc775e0709] refactor(store): simplify nextID restoration in load()
21 changes: 21 additions & 0 deletions evidence/lab2/18-bad-commit.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
commit f285ede8611e55ac0a7d01100891c0cc775e0709
Author: Dmitrii Creed <creeed22@gmail.com>
Date: Fri Jun 5 13:36:56 2026 +0400

refactor(store): simplify nextID restoration in load()

Signed-off-by: Dmitrii Creed <creeed22@gmail.com>

diff --git a/app/store.go b/app/store.go
index beaa436..7ea7c12 100644
--- a/app/store.go
+++ b/app/store.go
@@ -51,7 +51,7 @@ func (s *Store) load() error {
}
for _, n := range notes {
s.notes[n.ID] = n
- if n.ID >= s.nextID {
+ if n.ID > s.nextID {
s.nextID = n.ID + 1
}
}
1 change: 1 addition & 0 deletions evidence/lab2/19-range-size.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
4
Loading