This is a simple blog application built with Go (Golang) and Echo framework. It allows users to create, view, edit, and delete blog posts.
- Create blog posts with a title, description, and content.
- View individual blog posts.
- Edit existing blog posts.
- Delete blog posts.
- Upload and serve images for blog posts.
- Go (Golang)
- Echo framework
- SQL database (SQLite, MySQL, PostgreSQL, etc.)
-
Clone the repository:
git clone https://github.com/Kei-K23/go-blog-app.git
-
Navigate to the project directory:
cd go-blog-app
-
Create a
.env
file in the project root and specify your database connection URL:DB_URL=<your_database_connection_url>
-
Install dependencies:
go mod tidy
-
Build and run the application:
go run main.go
The application uses a SQL database to store blog posts. Make sure you have a SQL database server installed and running.
By default, the application uses Turso (SQLite). If you want to use a different database (MySQL, PostgreSQL, etc.), you'll need to modify the database driver and connection URL in the code.
- Access the application by visiting
http://localhost:8080
in your web browser. - Click on the "Create New Blog" button to create a new blog post.
- Click on a blog post title to view its details.
- Click on the "Edit" button to edit a blog post.
- Click on the "Delete" button to delete a blog post.
Feel free to contribute to the project and improve its features!