Skip to content

lylo/pagecord

Repository files navigation

Pagecord

Publish your writing effortlessly. All you need is email.

https://pagecord.com

Development

Quick Start with Docker

The easiest way to get Pagecord running locally is with Docker.

First, install Docker Desktop and make sure it's running.

Then:

git clone https://github.com/lylo/pagecord.git
cd pagecord
docker-compose up

This will:

  • Start PostgreSQL, Redis, and Memcached containers
  • Build and run the Rails app
  • Set up the database automatically

You can view the app at http://localhost:3000. It's configured to use lvh.me, so you can view individual blogs on their respective subdomains, e.g. http://joel.lvh.me:3000.

Running commands in Docker

# Rails console
docker-compose exec web bin/rails console

# Run tests
docker-compose exec web bin/rails test
docker-compose exec web bin/rails test:system

# Run migrations
docker-compose exec web bin/rails db:migrate

# Process emails (debug)
docker-compose exec web bash -c "DIR=tmp/emails rake email:load"

Native Development (Alternative)

If you prefer to run Rails natively without Docker:

Click to expand native setup instructions

Install Ruby 3.4.5+ using HomeBrew and rbenv.

bundle install
rails db:setup
brew install redis postgresql
bin/dev

Run tests:

bin/rails test
bin/rails test:system

Processing an email locally

Sometimes you'll need to debug emails. To do this, save the .eml file(s) to a folder such as tmp/emails.

You can then run the following command which will parse all the .eml files in that folder and create posts for the first user account in the seed data ([email protected]).

DIR=tmp/emails rake email:load

More info

Read about the Pagecord architecture or making contributions.

Follow the Pagecord blog.

Buy Me A Coffee

About

Blogging as easy as sending an email.

Topics

Resources

License

Unknown, Unknown licenses found

Licenses found

Unknown
LICENSE.md
Unknown
LICENSE-SUMMARY.md

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •