saloon

A place to chat and communicate: a buffalo forum

  • 所有者: go-saloon/saloon
  • 平台:
  • 許可證:
  • 分類:
  • 主題:
  • 喜歡:
    0
      比較:

Github星跟蹤圖

Saloon

Build Status
GoDoc

Saloon is a Work in Progress forum based on Buffalo.

Database setup

One needs a database to run saloon.
Here is an example, running postgres inside a docker container:

$> docker run --name saloon-postgres -e POSTGRES_PASSWORD=postgres -p 5432:5432 -d postgres

Create Your Databases

Ok, so you've edited the "database.yml" file and started postgres, now Buffalo can create the databases in that file for you:

$> buffalo db create -a
v4.2.0

created database saloon-test
created database saloon-prod
created database saloon-dev

You can run saloon to initialize the forum and the content of its database:

$> saloon migrate
> create_users
> create_categories
> create_topics
> create_replies
> create_forums

0.6591 seconds

$> saloon t db:setup
DEBU[2018-03-20T15:39:44+01:00] INSERT INTO users (admin, avatar, created_at, email, full_name, id, password_hash, subscriptions, updated_at, username) VALUES (:admin, :avatar, :created_at, :email, :full_name, :id, :password_hash, :subscriptions, :updated_at, :username)
DEBU[2018-03-20T15:39:44+01:00] INSERT INTO forums (created_at, description, id, logo, title, updated_at) VALUES (:created_at, :description, :id, :logo, :title, :updated_at)

The db:setup task created an admin user with (by default) a password admin.
You change that!

Starting the Application

Buffalo ships with a command that will watch your application and automatically rebuild the Go binary and any assets for you.
That's useful when developing on saloon.
To do that run the "buffalo dev" command:

$> buffalo dev

If you point your browser to http://127.0.0.1:3000 you should see a "Welcome to the Saloon Forum" page.

In production, one can instead directly run the saloon executable:

$> saloon
INFO[0000] Starting application at 127.0.0.1:3000
INFO[2018-03-20T15:40:31+01:00] Starting Simple Background Worker
[...]

Screenshots

Welcome page

00-home

Register a new user

01-register

Logged in

02-logged

Create a category

03-create-category
04-create-category-ok

Create a topic

05-create-topic
06-create-topic

Reply to a topic

07-reply
08-reply

Topics

09-topics

User settings

10-users-settings

主要指標

概覽
名稱與所有者go-saloon/saloon
主編程語言Go
編程語言Dockerfile (語言數: 5)
平台
許可證
所有者活动
創建於2020-08-24 20:16:32
推送於2020-08-30 18:24:16
最后一次提交2020-08-30 15:24:17
發布數0
用户参与
星數2
關注者數1
派生數0
提交數7
已啟用問題?
問題數0
打開的問題數0
拉請求數1
打開的拉請求數0
關閉的拉請求數1
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?