@@ -11,21 +11,10 @@ Before you start, make sure you have the following installed:
1111### Required Tools
1212
1313- ** Go** : [ Download Go] ( https://go.dev/dl/ )
14- - Verify installation: ` go version `
15- - ** Docker with BuildKit support** : [ Install Docker] ( https://docs.docker.com/engine/install/ )
16- - Verify installation: ` docker version ` and ` docker buildx version `
14+ - ** Docker** : [ Install Docker] ( https://docs.docker.com/engine/install/ )
15+ - It is recommended to enable [ Containerd Image Store] ( https://docs.docker.com/engine/storage/containerd/ ) for local image support. It is enabled by default in new installations.
1716- ** Git** : For version control
18- - Verify installation: ` git --version `
1917- ** Make** : For running development tasks (usually pre-installed on Linux/macOS)
20- - Verify installation: ` make --version `
21-
22- ### Optional Tools
23-
24- - ** Node.js 18+** : For building and running the documentation site locally
25- - Verify installation: ` node --version `
26- - [ Download Node.js] ( https://nodejs.org/ )
27- - ** golangci-lint** : For additional linting (the Makefile can run linting in Docker if not installed)
28- - [ Install golangci-lint] ( https://golangci-lint.run/usage/install/ )
2918
3019## Setting Up Your Development Environment
3120
@@ -115,16 +104,22 @@ make test-integration
115104
116105### 5. Test Frontend Image
117106
118- If you need to test the frontend as a Docker image :
107+ If you want to test the frontend with your spec files :
119108
120109``` bash
121110# Build the frontend image
122111make frontend
123112
124- # Build examples
125- make examples
126-
127113# Build and test with a specific target
114+
115+ # Container example
116+ docker build -t go-md2man:test \
117+ --build-arg BUILDKIT_SYNTAX=local/dalec/frontend \
118+ -f docs/examples/go-md2man.yml \
119+ --target=azlinux3/container \
120+ -t go-md2man:test .
121+
122+ # RPM example
128123docker build -t go-md2man:test \
129124 --build-arg BUILDKIT_SYNTAX=local/dalec/frontend \
130125 -f docs/examples/go-md2man.yml \
@@ -134,8 +129,6 @@ docker build -t go-md2man:test \
134129
135130## Available Make Targets
136131
137- The Makefile leverages ` docker-bake.hcl ` for build orchestration. Run ` make help ` to see all available targets:
138-
139132``` bash
140133make help
141134```
@@ -169,13 +162,6 @@ Key targets include:
169162
170163## Testing Your Changes
171164
172- ### Quick Tests (Run Frequently)
173-
174- ``` bash
175- # Unit tests only
176- make test
177- ```
178-
179165### Understanding the Test Structure
180166
181167Dalec has two types of tests:
@@ -226,21 +212,6 @@ The integration tests use a custom framework in `test/testenv/` that:
226212- ` windows_test.go ` - Windows container build tests
227213- And more...
228214
229- ### Validation Before Committing
230-
231- ** Always run before creating a pull request:**
232-
233- ``` bash
234- make verify
235- ```
236-
237- This ensures:
238-
239- - ✅ All unit tests pass
240- - ✅ Code passes custom linters
241- - ✅ Generated files are up to date
242- - ✅ No formatting issues
243-
244215### Integration Tests (Run for Significant Changes)
245216
246217Integration tests are comprehensive and time-consuming. Run them for significant changes or when modifying target-specific code:
@@ -271,23 +242,6 @@ go test -v -run TestSpecLoad ./...
271242go test -race ./...
272243```
273244
274- ## Using the Makefile
275-
276- The Makefile provides convenient shortcuts for common development tasks.
277-
278- ### Essential Commands
279-
280- | Command | Description |
281- | --------------- | ---------------------------------- |
282- | ` make help ` | Show all available commands |
283- | ` make generate ` | Generate required source files |
284- | ` make lint ` | Run custom linters |
285- | ` make lint-all ` | Run golangci-lint + custom linters |
286- | ` make test ` | Run unit tests |
287- | ` make build ` | Build all binaries |
288- | ` make verify ` | Run all verification steps |
289- | ` make clean ` | Clean build artifacts |
290-
291245## Common Development Tasks
292246
293247### Adding a New Source Type
@@ -318,11 +272,6 @@ The Makefile provides convenient shortcuts for common development tasks.
318272### Working on Documentation
319273
320274``` bash
321- # Install Node.js dependencies (first time only)
322- cd website
323- npm install
324- cd ..
325-
326275# Start the documentation server
327276make docs-serve
328277
@@ -332,18 +281,10 @@ make docs-serve
332281
333282## Best Practices
334283
335- ### Before Committing
336-
337- Always run:
338-
339- ``` bash
340- make verify
341- ```
342-
343284### Code Style
344285
345286- Follow standard Go conventions
346- - Run ` gofmt ` (included in ` make lint-all ` )
287+ - Run ` gofmt ` (included in ` make lint ` )
347288- Add comments for exported functions and types
348289- Write tests for new functionality
349290
@@ -371,10 +312,3 @@ make verify
371312- ** Documentation** : [ https://azure.github.io/dalec/ ] ( https://azure.github.io/dalec/ )
372313- ** Issues** : [ https://github.com/Azure/dalec/issues ] ( https://github.com/Azure/dalec/issues )
373314- ** Discussions** : [ https://github.com/Azure/dalec/discussions ] ( https://github.com/Azure/dalec/discussions )
374-
375- ## Next Steps
376-
377- - Read the [ main CONTRIBUTING.md] ( https://github.com/Azure/dalec/blob/main/CONTRIBUTING.md ) for CLA and contribution guidelines
378- - Explore the documentation to understand Dalec's features
379- - Look at [ example specs] ( https://github.com/Azure/dalec/tree/main/docs/examples ) to understand the declarative format
380- - Check out [ good first issues] ( https://github.com/Azure/dalec/labels/good%20first%20issue )
0 commit comments