Skip to content

Comments

feat: add docker build and docker file#18

Open
yacosta738 wants to merge 20 commits intoarsham:masterfrom
yacosta738:master
Open

feat: add docker build and docker file#18
yacosta738 wants to merge 20 commits intoarsham:masterfrom
yacosta738:master

Conversation

@yacosta738
Copy link

This pull request introduces Docker support for the project, simplifies the Makefile by removing unused targets, and updates the documentation to reflect these changes. The key updates are organized into the following themes:

Docker Support

  • Added a multi-stage Dockerfile to build and run the application using Docker. The build stage compiles the Go binary, and the final stage uses Alpine Linux to package the binary.
  • Updated the Makefile with new Docker-related targets: docker-build, docker-run, and docker-clean, simplifying Docker image and container management.

Build and Development Workflow

  • Simplified the Makefile by removing unused or redundant targets (e.g., platform-specific builds, release creation, and audit tasks) and focusing on core tasks like build, install, test, and clean.
  • Added a basic build task to the .devcontainer/devcontainer.json file to support containerized development environments.

Documentation Updates

  • Updated the README.md to include a new "Docker" section with instructions for building, running, and cleaning up the Docker image and container.
  • Adjusted the table of contents in README.md to include the "Docker" section.

yacosta738 and others added 20 commits April 30, 2025 15:40
Add Docker support for the `figurine` application.

* **Dockerfile**: Add a `Dockerfile` to build the Docker image using a multi-stage build. Set the working directory to `/app`, copy the `figurine` binary to the final image, and set the entrypoint to the `figurine` binary.
* **Makefile**: Add `docker-build`, `docker-run`, and `docker-clean` targets to build, run, and clean up the Docker image and container.
* **README.md**: Add a new "Docker" section with instructions to build, run, and clean up the Docker image and container.
* **.devcontainer/devcontainer.json**: Add a devcontainer configuration file with a build task for the `figurine` application.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/yacosta738/figurine?shareId=XXXX-XXXX-XXXX-XXXX).
Removed unused targets and streamlined Docker commands for better clarity and maintenance.
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Add Docker support for figurine
…ve security

- Upgrade Go version to 1.20
- Add support for building multi-platform Docker images
- Create non-root user for security
- Copy only the binary from the build stage
- Update README with build instructions
feat(docker): ✨ update Dockerfile for multi-platform builds and improve security
Ensure safe removal of binary file if it exists
Enhance compatibility by refining the method for locating the binary in the extracted archive, including support for OS and architecture suffixes.
…d fallback

Improve error handling for fetching latest release information using curl and wget. Add support for jq for JSON parsing and implement a fallback release tag.
Ensure that the checksum entry exists before verification to prevent installation errors.
…trict mode

Improve code clarity by moving the banner printing function and enforcing strict mode settings.
Enhance the installer script to allow users to specify a custom GitHub repository for installation, improving flexibility and usability.
Enhance error handling for checksum verification by allowing continuation if checksums file is missing or mismatched.
fix(install): 🐛 improve checksum verification process
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant