A user-friendly CMS written in Go (golang)

Overview

Fragmenta CMS

Fragmenta CMS

Fragmenta CMS is a user-friendly Content Management System built with Go. For more information and a demo of the CMS in action, see the website at http://fragmenta.eu

Usage

Config

Session Name

The session_name key is used to set the name used in cookies.

Theme

The theme key is used to set the theme. To use a theme, add a key with the name of your theme folder to the fragmenta.json file. Theme templates will then override any templates in the app at the same path.

Requirements

Go 1.8 is now required, as some new features from this release and the 1.7 release are used.

Version History

Comments
  • I keep getting

    I keep getting "You must create your project in $GOPATH/src"

    No matter what path I use even if it matches both the $GOPATH/src does not work because I get the "You must create your project in $GOPATH/src" error and I can't find a solution to the problem. Here are the paths I have tried ($GOPATH = C:/Gosites)

    C:/Gosites C:/Gosites/src C:/Gosites/src/github.com C:/Gosites/src/github.com/app

    And all of them give me the same error?

    I have tried changing if !strings.HasPrefix(projectPath, path.Join(os.Getenv("GOPATH"), "src")) { to if !strings.HasPrefix(projectPath, filepath.Join(os.Getenv("GOPATH"), "src")) {

    But no success? Please advise me on what I can do to solve this.


    go version = go version go1.7 windows/amd64

    opened by thorad 10
  • fragmenta server results in

    fragmenta server results in "a:unable to compile assets error:open public/assets/scripts/app-9ad47a746ac7acfa883dafa4ae0db5721bcea629.min.js: The system cannot find the path specified."

    On a fresh installation of cms in Windows 10 with go 1.8:

    fragmenta new cms xxx (project generated) fragmenta migrate (the server role and development db was created)

    Then.....run the following in bash shell:

    $ fragmenta server 16:47:04

    Fragmenta version: 1.5rc

    16:47:04 Building server... 16:47:04 Running go fmt at ./... 16:47:05 Building server at d:\xxx\xxx\go\src\xxx\xxx/bin/fragmenta-server-local 16:47:06 Build completed successfully in 1.2570401s 16:47:06 Launching server... 2017-06-20:08:47:06 Starting server port:3000 #info 2017-06-20:08:47:06 Compiling Asssets #info 2017-06-20:08:47:06 a:unable to compile assets error:open public/assets/scripts/app-9ad47a746ac7acfa883dafa4ae0db5721bcea629.min.js: The system cannot find the path specified. #fatal

    opened by AP-Nothize 7
  • Logging out doesn't redirect properly.

    Logging out doesn't redirect properly.

    Setup brand new fragmenta site. Log in. Then click the logout link. Instead of redirecting to "/" it shows a 404. Examining the logs it shows a very strange set of events:

    2016/03/23 21:43:26 #info Started GET /users/logout for {my ip}
    2016/03/23 21:43:26 #info Started POST /users/logout for {my ip}
    2016/03/23 21:43:26 #info Handling with route [POST] /users/logout
    2016/03/23 21:43:26 #info Handling with route [GET] /{path:[a-z0-9]+}
    2016/03/23 21:43:26 #info Redirecting (302) to path:/
    2016/03/23 21:43:26 #info Finished POST /users/logout for {my ip} status 200 in 1.35173ms
    2016/03/23 21:43:26 #error Status 404 at src/pages/actions/show.go:44 : Error:404
    2016/03/23 21:43:26 #info Started GET / for {my ip}
    2016/03/23 21:43:26 #info Handling with route [GET] /
    2016/03/23 21:43:26 #info Finished GET / for {my ip} status 200 in 16.520678ms
    

    Why is there a log for a POST? I tried digging around but I think somewhere the request isn't following through all the way (maybe?) Tried on Chrome and Firefox, same result.

    opened by chriseaton 6
  • Pass lint, vet and consolidate.

    Pass lint, vet and consolidate.

    Love the fact there is a CMS in Go!

    I have taken the time to go through the codebase and endure it passes golint, go vet, all fucntions and methods are commented correctly for godoc and made some changes to the way roles are queried to make it less repetitive. Hope this helps, especially if you'd like to attract contributors. I have the following settings in GoSublime if you use that:

    "on_save": [{
          "cmd": "gs9o_open", "args": {
            "run": ["sh",
              "errcheck && godep go build . errors && godep go test -i && godep go test && go vet && golint ."],
        "focus_view": false
        }}],
        "autocomplete_closures": true,
        "complete_builtins": true,
    

    Hope this helps! All tests are passing but I did notice the following which was already issuing a warning:

    src/lib/mail/mail.go:46: cannot use renderContext literal (type *renderContext) as type view.RenderContext in argument to view.New:
        *renderContext does not implement view.RenderContext (missing Writer method)
    src/lib/mail/mail.go:53: view.RenderString undefined (type *view.Renderer has no field or method RenderString)
    
    opened by buddhamagnet 5
  • DB connection

    DB connection

    I have my DB running in a separate instance. I cannot find a way to define the connection string. It always tries to connect to localhost. Where can I find some help?

    opened by chasseurmic 5
  • Stuck on fresh installation of Fragmenta cms

    Stuck on fresh installation of Fragmenta cms

    Im a new be for golang development, using windows 10 and my go Lang configuration setup as per the below details.

    C:\work>go env set GOARCH=amd64 set GOBIN= set GOEXE=.exe set GOHOSTARCH=amd64 set GOHOSTOS=windows set GOOS=windows set GOPATH=c:\work set GORACE= set GOROOT=C:\Go set GOTOOLDIR=C:\Go\pkg\tool\windows_amd64 set CC=gcc set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 set CXX=g++

    set CGO_ENABLED=1

    I can run any go example projects in local.

    Installed fragmenta as instructed in http://fragmenta.eu/install

    C:\work>go get -u github.com/fragmenta/fragmenta then use C:\work>fragmenta new cms testcms Getting this below error when i run this above line, am not sure why its ask me like this, please correct me, where am wrong. "17:50:01 You must create your project in $GOPATH/src" tried in this location to C:\work\src>fragmenta new cms testcms but same above message.

    opened by rahu431 4
  • Addons

    Addons

    Hi guys,

    Hope you are doing well !

    I was looking at your repo, saying to myself finally a good CMS oriented project, written in Go ! :-)

    I want to suggest the following list of addons:

    • [ ] 1. Elasticsearch client for Go: https://github.com/olivere/elastic
    • [ ] 2. A modern text indexing library for go: https://github.com/blevesearch/bleve
    • [ ] 3. Go utility for ElasticSearch and Bleve: https://github.com/dorsha/lennon
    • [ ] 4. HTTP/REST/JSON front-end to bleve: https://github.com/blevesearch/bleve-explorer
    • [ ] 5. AngularJS admin GUI to any RESTful API : https://github.com/marmelab/ng-admin
    • [ ] 6. Faster performance web framework https://github.com/gin-gonic/gin
    1. Would help to scale the volume of tags or posts, you could publish
    2. Would implement some advanced full-text search functions and the addons like bleve explorer
    3. Would merge the benefits of the 2 above
    4. & 5. A Rest API would simplify how to build custom Admin GUI.

    Did u shaped a roadmap for your project ? Maybe I missed the link :-)

    Fragmenta sounds really promising :-)

    Cheers, Luc

    opened by ghost 4
  • error creating admin user

    error creating admin user

    First pass after reorg to using gb build all

    ./bin/server

    Using Postgres running on my local (Mac) system, from brew install postgresql (Highly possible it's not setup correctly.) It's v9.4.5 if that helps.

    
    Error:Error querying database for count: pq: relation "users" does not exist
    Query:SELECT COUNT("id") FROM "users" WHERE (email=$1);
    
    screen shot 2015-11-24 at 8 25 43 pm
    opened by cmosetick 4
  • restructure project to use `gb` for reproducible builds

    restructure project to use `gb` for reproducible builds

    gb is the preferred tool now for building and managing go projects, because gb can guarantee reproducible builds. This means that everything is self contained in the "project dir" and simplifies the differences between development and production environments. http://getgb.io/docs/usage/ video intro to gb

    Also, review the vendor plugin: https://godoc.org/github.com/constabulary/gb/cmd/gb-vendor

    I'm having issues with fragmenta no matter where my project is located on my local system.

    I'm having issues with absolute paths. Here, I placed my fragmenta "site" in my "gocode dir", which is in my path, but even in another location, I'm having trouble.

    fragmenta
    12:23:24
    ------
    Fragmenta version: 1.3.1
    ------
    12:23:24 Building server...
    12:23:24 Running goimports at ./
    12:23:24 Building server at /Users/chris/src/gocode/fragmenta/bin/fragmenta-server-local
    12:23:24 CMD go build -o /Users/chris/src/gocode/fragmenta/bin/fragmenta-server-local server.go
    server.go:8:2: import "/Users/chris/src/gocode/fragmenta/src/app": cannot import absolute path
    12:23:24 Error running build exit status 1
    12:23:24 Error building server: exit status 1
    
    wontfix 
    opened by cmosetick 4
  • I can't pass null value to database

    I can't pass null value to database

    Whenever we have null value that needs to be persisted in database, the map in pages.Update() prevents as from doing so as the type of the map to be persisted is map[string]string and such map doesn't accept null as value We think that if it was implemented map[string]*string/ map[string]interface this would get over this issue. Thanks in advance

    opened by shahendaeldeeb 3
  • It needs a basic tutorial

    It needs a basic tutorial

    Please, I no have idea how to start after install it.

    Please, I would like to know if it has multi lang support for templates? How works the template manager ? Can use it to make a multilanguage post app?

    Thanks a lot, great work

    duplicate 
    opened by suxonca 3
  • uploaded file management

    uploaded file management

    wordpress, drupal etc all made the uploaded files publicly accessible by default, you always need some extra plugin to protect those files, in many cases they did not work.

    how does fragmenta handle this? if I upload a file, can I make that private, i.e. unless you're a logged in user, there is no way you can download that file.

    opened by laoshaw 0
  • Runtime editable templates feature discussion

    Runtime editable templates feature discussion

    I was wondering if the templates themselves can be editted in the web GUI as part of an admin section.

    My usecase is to allow Designers to create and control the templates. They use the existing datamodels available. I think it might be possible to lookup the data binding so the user can see possible data fields based on the templates context also. On the right they can see the final result as they edit the template. In short it's very similar to a markdown editor.

    I think that this would also make it much easier for golang developers to make templates since you have instant feedback.

    The exact approach for setting up the context of the databinding I am not sure about yet. For instance maybe the user would select a table in the database and use that as a context. Not sure yet.

    The other thing is that the templates are added, editted and deleted at runtime. So these would have to live stored someone. The file system seems the most sensible

    What do we think about this ?

    opened by ghost 1
  • Database user is configurable but hard-coded in migrations

    Database user is configurable but hard-coded in migrations

    The credentials for the database are configurable in secrets/fragmenta.json. However, the default migrations in db/migrations/*.sql also contain hard-coded usernames & passwords.

    Why not simply create the user and database itself from the info in secrets/fragmenta.json? That would remove the need to have usernames & passwords in xxxx-Create-Database.sql.

    When connecting to the database to perform migrations, wouldn't tables already be owned by the creating user? If I'm right in that, all the ALTER TABLE xxx OWNER TO "yyy"; lines can be removed from xxx-Create-Tables.sql.

    Of course this requires the database connection to be made with the correct credentials, which might not be the case (see https://github.com/fragmenta/fragmenta/issues/32).

    Furthermore, I believe that migrations are files that should be loadable on any installation of the site, while the username/password credentials are installation-specific. This is exacerbated by the fact that test, development, and deploy configurations in secrets/fragmenta.json can be configured to use different usernames. Having those usernames hard-coded in the migration files makes no sense.

    opened by sybrenstuvel 1
  • Handle multiple domains

    Handle multiple domains

    The CMS should let you serve pages on multiple domains. At present the assumption is that each server only serves one domain.

    This would require:

    • Add domains resource with at minimum name, aliases
    • Change pages, posts, tags to be domain specific with a domain_id col
    • Not sure if users should be shared or independent, there are arguments for both
    • Handle https - see server issue on multiple https domains
    opened by kennygrant 5
  • Proposal: Parse JSON params in mux

    Proposal: Parse JSON params in mux

    In github/fragmenta/mux/params.go file line (52), it supports either "application/x-www-form-urlencoded" or "multipart/form-data" only, is there any reason behind not including JSON datatype? Are you planning to include it in any coming release? Thanks in advance .

    opened by shahendaeldeeb 1
Owner
Fragmenta
Building websites with go
Fragmenta
notion-md-gen allows you to use Notion as a CMS for pages built with any static site generators

notion-md-gen allows you to use Notion as a CMS for pages built with any static site generators

Bonaysoft 62 Sep 6, 2022
GoTrue is a small open-source API written in Golang, that can act as a self-standing API service for handling user registration and authentication for Jamstack projects.

GoTrue is a small open-source API written in Golang, that can act as a self-standing API service for handling user registration and authentication for Jamstack projects.

null 2 Dec 13, 2021
:construction: Closed. A website and user system (Gin/Backbone).

A website and user system starter. Implemented with gin and Backbone. Gowall is port of Drywall Go Node.js Repository here Drywall Site Gowall Drywall

Petr 34 Jul 6, 2020
Everything a semantic desktop search engine combined with a single-user document management system

Everything will be a semantic desktop search engine combined with a single-user document management system. It will apply ideas of the semantic web and knowledge graphs to organize your data, allowing you to maintain private knowledge graphs as well as make use of public knowledge graphs, such as Wikidata.

Dominik Honnef 22 May 21, 2022
Birthdays is a web service that stores the birthday date of users and calculates the remaining days until the user's birthday.

Birthdays is a web service that stores the birthday date of users and calculates the remaining days until the user's birthday. Features Metrics servic

Hugo Meneses 1 May 2, 2022
A library to curb OOMs by running Go GC according to a user-defined policy

Go memory watchdog ?? A library to curb OOMs by running Go GC according to a user-defined policy. Package watchdog runs a singleton memory watchdog in

Rohan 0 Nov 26, 2021
Extensible wiki system using CouchDB and written in Golang

Wikifeat Introduction Wikifeat is an open source collaboration platform built around the ever-popular Wiki concept. It is meant to be extensible and h

James Adam 100 Aug 23, 2022
Forms is a fast, powerful, flexible, sortable web form rendering library written in golang.

forms Description forms makes form creation and handling easy. It allows the creation of form without having to write HTML code or bother to make the

coscms 21 Jun 15, 2022
A social media API to handle users and their posts, written from scratch in Golang

Initial Set-Up To start the project on your own machine you'll need Golang instlled, along with mongoDB. Once you've insured these requirements are me

Ayush Neekhar 0 Oct 9, 2021
A simple web application written in Golang which listens on port 8080

GoWebApp It's a simple web application written in Golang which listens on port 8080 Building It can be build using the command go build -o metricsweba

Viral Kamdar 0 Oct 21, 2021
A coinbase Golang API written in Go

A coinbase Golang API written in Go

Evan 0 Oct 29, 2021
A simple demo written in Golang to shorten URL and redirect

url-shortener A simple demo written in Golang to shorten URL and redirect . ├── go.mod ├── go.sum ├── handler │ └── handlers.go ├── main.go ├── shor

lunarwhite 1 Jun 5, 2022
A minimal honeypot written in Golang.

bucket - A minimal honeypot written in Golang. A honeypot written in Golang that enumerates connected clients, logs activity, and more! Features Featu

null 2 Dec 2, 2021
A Binance Chain vanity address generator written in golang

VaniBNB A Binance Chain vanity address generator written in golang. For example address ending with 0xkat Raw https://github.com/makevoid/vanieth http

null 0 Dec 14, 2021
Simple URL shortener written in Golang

Alviss Introduction Simple URL shortener project, written in Golang. Setup and r

Amir Iravanimanesh 22 Aug 25, 2022
Account Generator Bot, written in GoLang via gotgbot library

Account Generator Bot Account Generator Bot, written in GoLang via gotgbot library. Variables Env Vars - BOT_TOKEN - Get it from @BotFather CHANNEL_ID

Dileepa_Malshan 0 Dec 28, 2021
A todo app written in Golang, MongoDB, and React.

A todo app written in Golang, MongoDB, and React.

yuedong.w 0 Jun 5, 2022
A RESTful API written in Golang to store and retrieve ticket information.

Tickets-API A RESTful API written in Golang to store and retrieve ticket information. This is a RESTful API built on top of the gin-gonic/gin package

Komi Alasse 0 Jan 31, 2022
Goals calendar is a Seinfeld calendar written in Google's Go (unfinished dead code)

Goals calendar ============== Goals calendar is a Seinfeld calendar written in Google's Go. Mark a red check each day you have done something for you

Bruno Michel 15 Jun 5, 2017