Skip to content

Commit 6fa0f45

Browse files
FortinbrafortinbraCopilot
authored
chore: remove legacy scripts and scrub docs to CI/CD pull-based deployment (#2)
* chore: remove legacy scripts and scrub docs to CI/CD pull-based deployment\n\n- remove legacy-scripts/ directory\n- update README.md, README.Docker.md, DEPLOY-QUICKSTART.md, docs/ci-cd-deployment.md\n- update .github/copilot-instructions.md note on legacy scripts removal\n- clean .dockerignore of removed script entries * Update README.Docker.md Co-authored-by: Copilot <[email protected]> * Update README.Docker.md Co-authored-by: Copilot <[email protected]> * chore: remove Docker deployment guide from README --------- Co-authored-by: fortinbra <[email protected]> Co-authored-by: Copilot <[email protected]>
1 parent 1d3a929 commit 6fa0f45

File tree

13 files changed

+27
-1666
lines changed

13 files changed

+27
-1666
lines changed

.dockerignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,7 @@ docs/
3737
**/*.Tests/
3838

3939
# Deployment scripts
40-
deploy.ps1
41-
deploy.sh
40+
4241
docker-compose.yml
4342
docker-compose.*.yml
4443

.github/copilot-instructions.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,7 @@ Tests under `tests/` mirroring structure:
3333
- ASP.NET Core API
3434
- EF Core + Npgsql (PostgreSQL)
3535
- xUnit (unit tests) + Shouldly OR built-in Assert (NO FluentAssertions, NO AutoFixture)
36-
- Bogus (optional) only if lightweight test data required (avoid over-randomization)
3736
- Mapping: manual or source generators (avoid AutoMapper until justified)
38-
- Validation: FluentValidation (if adopted) OR minimal custom validation; keep consistent.
3937

4038
## 5. Naming & Conventions
4139
- C# Style: PascalCase types/members (except local variables & private fields). Private fields: `_camelCase`.
@@ -235,6 +233,6 @@ Keep this file lean—prune when obsolete. Update when architectural decisions s
235233
- **Dockerfile**: Multi-stage build (`Dockerfile`) - builds from source, no pre-build required.
236234
- **Deployment**: Raspberry Pi uses `docker-compose.pi.yml` to pull and run images from ghcr.io.
237235
- **Database Connection**: Passed via environment variable `ConnectionStrings__AppDb` from `.env` file (never committed).
238-
- **Legacy Scripts**: Local build scripts (`build-docker-windows.ps1`, `deploy-to-pi.ps1`, etc.) moved to `legacy-scripts/` and deprecated.
236+
- **Legacy Scripts**: All legacy local build/deploy scripts (e.g., `build-docker-windows.ps1`, `deploy-to-pi.ps1`, `deploy.sh`) have been removed from the repository. Do not add or reference local Docker scripts. Use CI/CD-built images and deploy by pulling with `docker compose` on the target device.
239237
- **Documentation**: See `README.Docker.md` for deployment guide, `DEPLOY-QUICKSTART.md` for quick Pi setup.
240238
- **Important**: Do NOT create or suggest local Docker build workflows. Direct users to CI/CD pipeline or standard .NET local development.

DEPLOY-QUICKSTART.md

Lines changed: 17 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -166,35 +166,21 @@ Open a browser and navigate to:# Test passwordless login
166166

167167

168168

169-
## Common Commands### Option 1: One-Command Deployment (Easiest)
170-
171-
172-
173-
```bashFrom your Windows machine, in the project root directory:
169+
## Common Commands
174170

171+
```bash
175172
# View logs
173+
docker compose -f docker-compose.pi.yml logs -f
176174

177-
docker compose -f docker-compose.pi.yml logs -f```powershell
178-
179-
# Replace 'raspberry-pi.local' with your Pi's hostname or IP address
180-
181-
# Stop application.\deploy-to-pi.ps1 -PiHost raspberry-pi.local -PiUser pi
182-
183-
docker compose -f docker-compose.pi.yml stop```
184-
185-
186-
187-
# Start applicationThis single command will:
188-
189-
docker compose -f docker-compose.pi.yml start1. ✅ Run all unit tests
190-
191-
2. ✅ Build the application for ARM64
192-
193-
# Update to latest version3. ✅ Create a Docker image
175+
# Stop application
176+
docker compose -f docker-compose.pi.yml stop
194177

195-
docker compose -f docker-compose.pi.yml pull4. ✅ Transfer everything to your Pi
178+
# Start application
179+
docker compose -f docker-compose.pi.yml start
196180

197-
docker compose -f docker-compose.pi.yml up -d5. ✅ Deploy and start the application
181+
# Update to latest image and redeploy
182+
docker compose -f docker-compose.pi.yml pull
183+
docker compose -f docker-compose.pi.yml up -d
198184

199185

200186

@@ -206,29 +192,14 @@ docker compose -f docker-compose.pi.yml ps
206192
207193
208194
209-
## Updating the Application#### Step 1: Build on Windows
210-
211-
```powershell
212-
213-
When new versions are released:.\build-docker-windows.ps1
195+
## Updating the Application
214196
215-
```
197+
When new versions are released:
216198
217199
```bash
218-
219-
cd ~/BudgetExperimentThis will:
220-
221-
docker compose -f docker-compose.pi.yml pull- Run tests
222-
223-
docker compose -f docker-compose.pi.yml up -d- Build the Docker image for ARM64
224-
225-
```
226-
227-
#### Step 2: Deploy to Pi
228-
229-
That's it! The new image will be downloaded and deployed automatically.```powershell
230-
231-
.\deploy-to-pi.ps1 -PiHost raspberry-pi.local -PiUser pi
200+
cd ~/BudgetExperiment
201+
docker compose -f docker-compose.pi.yml pull
202+
docker compose -f docker-compose.pi.yml up -d
232203

233204
## Troubleshooting```
234205

@@ -358,14 +329,7 @@ docker stats
358329

359330
## Updating the Application
360331

361-
When you make code changes:
362-
363-
```powershell
364-
# On Windows, just run the deployment again
365-
.\deploy-to-pi.ps1 -PiHost raspberry-pi.local -PiUser pi
366-
```
367-
368-
This will rebuild and redeploy automatically.
332+
When you make code changes and push to main, the CI/CD pipeline builds new images. On the Pi, pull and restart using the commands above.
369333

370334
## Accessing the Application
371335

@@ -390,11 +354,8 @@ Replace `raspberry-pi.local` with your Pi's IP address if hostname doesn't work.
390354
└─────────────────┘ └──────────────────┘ └─────────────┘
391355
```
392356
393-
## Files Created
357+
## Files
394358
395-
- `build-docker-windows.ps1` - Builds ARM64 Docker image on Windows
396-
- `deploy-to-pi.ps1` - Complete deployment script (build + transfer + deploy)
397-
- `load-and-deploy.sh` - Runs on Pi to load and start containers
398359
- `README.Docker.md` - Detailed Docker documentation
399360
- `DEPLOY-QUICKSTART.md` - This file
400361

0 commit comments

Comments
 (0)