Document FORGEJO_TOKEN setup for CI/CD
All checks were successful
Build and Push Docker Image / build-and-push (push) Successful in 11s

Add comprehensive documentation for setting up the personal
access token required for the Forgejo Actions CI/CD pipeline
to push Docker images to the container registry.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Kevin Sivic 2025-12-01 08:10:44 -05:00
parent 49c44beb72
commit 4bc996334f

View file

@ -9,6 +9,40 @@ Now you can visit [`localhost:4000`](http://localhost:4000) from your browser.
Ready to run in production? Please [check our deployment guides](https://hexdocs.pm/phoenix/deployment.html).
## Docker Deployment
See [DOCKER_README.md](DOCKER_README.md) for instructions on running the application with Docker Compose.
## CI/CD Setup
This project uses Forgejo Actions for continuous integration and deployment. The workflow automatically builds and pushes Docker images to the Forgejo container registry on every push to the main branch.
### Setting up the FORGEJO_TOKEN Secret
To enable the CI/CD pipeline to push Docker images to the container registry, you need to create a personal access token and add it as a repository secret:
1. **Create a Personal Access Token**:
- Go to your Forgejo instance and log in
- Click your profile icon → **Settings**
- Click **Applications** in the left sidebar
- Scroll to **Generate New Token**
- Give it a name (e.g., "GitHub Actions" or "CI/CD")
- Check the following permissions:
- ✅ **write:package** (required to push to container registry)
- ✅ **read:package** (required to pull from container registry)
- Click **Generate Token**
- Copy the token (you won't be able to see it again!)
2. **Add the Token as a Repository Secret**:
- Go to your repository in Forgejo
- Click **Settings** → **Secrets**
- Click **Add secret**
- Set **Name**: `FORGEJO_TOKEN`
- Set **Value**: Paste the token you copied
- Click **Add secret**
Once configured, the workflow will automatically build and push Docker images on every push to main.
## Learn more
* Official website: https://www.phoenixframework.org/