GithubHelp home page GithubHelp logo

feathercms / feather Goto Github PK

View Code? Open in Web Editor NEW
594.0 23.0 53.0 5.23 MB

Feather is a modern Swift-based content management system powered by Vapor 4.

Home Page: https://feathercms.com

License: MIT License

Swift 75.11% Makefile 24.89%
swift vapor-4 cms engine framework api web blogging journalism publishing

feather's Introduction

⚠️⚠️⚠️ Under construction ⚠️⚠️⚠️

Feather CMS is currently under construction, just a few things about the new version:

  • 100% async / await support (requires macOS 12+ or Linux)
  • Leaf / Tau is completely replaced with SwiftHtml
  • Simplified core library FeatherCore

Feather CMS

Feather CMS 🪶

🪶 Feather is a modern Swift-based content management system powered by Vapor 4.

💬 Click to join the chat on Discord.

Requirements

To use Feather you'll have to install Swift 5.5 or greater.

If you need help installing Swift, you should follow the official instructions available on swift.org.

Setup & environment

Clone or download the source files using the Feather repository.

git clone https://github.com/FeatherCMS/feather.git

Change the current working directory (located under the target setting when using Xcode) to the project directory.

cd feather

Create a dotenv file ( .env or .env.development) based on your environment) and config the following values.

# the base path (absolute) of the working directory
FEATHER_WORK_DIR="/path/to/feather/" 

# Optional Feather related env variables

# the hostname (domain) of your web server, default localhost
FEATHER_HOSTNAME=feathercms.com
# the port to listen on, default 8080
FEATHER_PORT=80
# use HTTPS, default false (needs cert & key setup on the Vapor app)
FEATHER_HTTPS=true
# maximum body size for file uploads
FEATHER_MAX_BODY_SIZE=10mb
# disable file middleware, default false (if disabled you can serve files with nginx)
FEATHER_DISABLE_FILE_MIDDLEWARE=true
# disable the session auth middleware for api endpoints (recommended for production)
FEATHER_DISABLE_API_SESSION_MIDDLEWARE=true

You can run the make env command to quickly create a development environment with the curret directory as a base path.

Start the server using the swift run Feather command (alternatively you can use the make run command).

Notes about using Xcode

  • ⚠️ Warning: DO NOT USE the swift package generate-xcodeproj command, it's deprecated.
  • ⚠️ Make sure that you open the project by double clicking the Package.swift file.
  • ⚠️ Set the custom working directory for the Feather scheme to the root of the project directory.
  • ⚠️ If needed setup a post-action script to automatically shut-down previous server instances (to avoid address in use errors).
  • ✅ Build and run the project as usual and enjoy your Feather powered site.

Configuration

The FeatherCore framework provides all the necessary API to configure your Feather application.

Database driver

By default Feather uses the SQLite driver, but it is possible to use PostgreSQL, MySQL (MariaDB) or even MongoDB as your database driver through the Fluent framework.

You should follow the instructions using the official Vapor docs to setup the right driver, but please note that the preferred drivers are PosgreSQL and SQLite for really small projects and development purposes.

File storage driver

The Liquid framework is an abstract file storage library that works with a local file storage driver, but it is also possible to use Amazon S3 as a cloud-based solution.

You can replace the default local driver with the S3 driver, which is powered by the Soto for AWS SDK.

Modules

Feather is a modular CMS system, you can add new modules as Swift package dependencies or place them under the Modules directory.

Feather gives you just a few core modules, they provide basic functionalies such as the route system, web frontend, admin interface or API layer.

The usage of other modules can be completely customized (just alter the SPM dependency & configuration file).

💡 Feel free to fork this repository and create your own configuration as per needed.

Using Feather CMS

Installation

The first time when you open your page Feather will run in install mode.

During this phase (behind the scenes):

  • all the required database structures will be created (database migration will run automatically).
  • Bundled resources (public files) will be copied to the project folder (if needed).
  • All the necesseary models will be installed (persisted) using the configured database driver.
  • All the required assets will be uploaded to the file storage (using the configured storage driver).
  • The "root" user account will be created, you have to provide yor own credentials during this step.
  • Sample content for the blog module will be created (you can opt-out from this).
  • You'll be redirected to the welcome page.

Now you are ready to use your Feather-based website.

User guide

You can read more about how to use Feather in the wiki.

Contribution and support

🪶 Feather is an open source software and your contributions are more than welcome.

🔀 If you wish to make a change, please open a Pull Request.

🙏 Please don't hesitate to send your feedbacks, thoughts and ideas about Feather.

Address already in use error

You can use the following command to kill the process listening on the 8080 port.

lsof -i :8080 -sTCP:LISTEN |awk 'NR > 1 {print $2}'|xargs kill -15

Tip: when using Xcode, edit the scheme and add this as a pre-action script.

Credits

feather's People

Contributors

tib avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

feather's Issues

Seg Fault 11 while trying to login for the first time

Hi,

I'm following your tutorial to make my own blog using your CMS and when I try to login for the first time with the given id and password, I get a segmentation fault 11. I have no idea what could have caused it and the server crashes. This appears only when running the server from terminal. Could it be caused by a chmod or chown setting ?
Capture d’écran 2020-08-17 à 22 42 12

Invalid username or password

Hello,
I'm new to this. I've just manage to install it in development environment. It doesn't seem to login and showing Invalid username or password.
Did I miss something during installation & configuration?

New docker image

Hi Tim

Many thanks for your efforts.
Is It possible to provide a docker file to create a container?
The old file allows create the image without errors, but it is not possible to run it.

I tried with "swift:5.5.2-focal as builder"

The log

`

docker run 7a1616d0ce5a

FeatherCore/Environment+Fetch.swift:24: Fatal error: The following key FEATHER_WORK_DIR is not defined in the environment file.
Check the README or the documentation for how to set environment variables.
Received signal 4. Backtrace:
0x55a06f3b5a92, Backtrace.(printBacktrace in _B82A8C0ED7C904841114FDF244F9E58E)(signal: Swift.Int32) -> () at /opt/feather/.build/checkouts/swift-backtrace/Sources/Backtrace/Backtrace.swift:66
0x7fa4e85c53bf
0x7fa4e88910ab
0x55a06f6ee07f, static (extension in FeatherCore):Vapor.Environment.featherRequired(Swift.String) -> Swift.String at /opt/feather/.build/checkouts/feather-core/Sources/FeatherCore/Extensions/Environment+Fetch.swift:24
0x55a06f6f7ce9, one-time initialization function for (workDir in _4CA58FEA3E295A70C8D04B97347E9C51) at /opt/feather/.build/checkouts/feather-core/Sources/FeatherCore/Feather/Feather.swift:22
0x7fa4e85c247e
0x7fa4e8b400d5
0x55a06f6f81e6, FeatherCore.Feather.(workDir in _4CA58FEA3E295A70C8D04B97347E9C51).unsafeMutableAddressor : Swift.String at /opt/feather/.build/checkouts/feather-core/Sources/FeatherCore/Feather/Feather.swift:22
0x55a06f6f81e6, one-time initialization function for base at /opt/feather/.build/checkouts/feather-core/Sources/FeatherCore/Feather/Feather.swift:35
0x7fa4e85c247e
0x7fa4e8b400d5
0x55a06f6f8353, FeatherCore.Feather.Paths.base.unsafeMutableAddressor : Foundation.URL at /opt/feather/.build/checkouts/feather-core/Sources/FeatherCore/Feather/Feather.swift:35
0x55a06f6f8353, one-time initialization function for public at /opt/feather/.build/checkouts/feather-core/Sources/FeatherCore/Feather/Feather.swift:38
0x7fa4e85c247e
0x7fa4e8b400d5
0x55a06f6f83a3, FeatherCore.Feather.Paths.public.unsafeMutableAddressor : Foundation.URL at /opt/feather/.build/checkouts/feather-core/Sources/FeatherCore/Feather/Feather.swift:38
0x55a06f6d300a, Feather.configure(Vapor.Application) throws -> () at /opt/feather/Sources/Feather/main.swift:23
0x55a06f6d2e96, Feather_main at /opt/feather/Sources/Feather/main.swift:42
0x7fa4e7e430b2
0x55a06f1dd9ad
0xffffffffffffffff
/opt/feather/start: line 5: 7 Illegal instruction Feather serve --hostname 0.0.0.0 --port ${BASE_PORT}

`

Nice year 2022.

BASE_PATH resolution results in crash

I installed feather as described in your blog post. In my .env.development file I configured the BASE_PATH as ~/git/feather/. This resulted in a crash-loop of Xcode when I ran the server. I noticed that when I tried to visit the server for the first time a folder named ~ was created in the root directory of the project. That resulted in a cash of the server and the debugger followed by Xcode.

To me it looks like that the path is not resolved correctly.

i18n Support

Thanks for your hard work; I like where FeatherCMS has gone so far. Is it possible to add i18n support? Or maybe there is already a way to do it?

Documentation about the BCrypt issue under macOS 10.15

Hi. I’m running from the macOS 11 command line using swift run and followed the README.md instructions.

Visiting login and entering user: [email protected] with password FeatherCMS gets this result:

[ INFO ] POST /login/ [request-id: 7454CFA2-BD23-4801-81E0-E95263B6979A]
[1]    43303 segmentation fault  swift run

I’ve tried this several times with the same problem. Same results with both SQLite and PostgreSQL. dropdb and creating a fresh db has the same result.

Use the `.data` type for longer text fields.

Initial sql error due to field size constraints when porting to MySql (and presumably postgres), but not Sqlite.

I found that migration defines two columns, called 'content' & 'excerpts' with data type '.string', not as '.data', consequently causes an error on initial start. The difference is due to data type '.string' limits the size to varchar(255), while '.data' is a blob or nearly un-limited size. The 'content' value is nearly 5k, exceeding the 255 size limit. Two cases where necessary switching to from '.string' to '.data'

  1. BlogMigration_v1_0_0

         db.schema(BlogPostModel.schema)
             .id()
             .field(BlogPostModel.FieldKeys.title, .string, .required)
             .field(BlogPostModel.FieldKeys.imageKey, .string, .required)
             .field(BlogPostModel.FieldKeys.**excerpt, .data,** .required) 
             .field(BlogPostModel.FieldKeys.**content, .data,** .required)
             .field(BlogPostModel.FieldKeys.categoryId, .uuid, .required)
             .field(BlogPostModel.FieldKeys.authorId, .uuid, .required)
             .foreignKey(BlogPostModel.FieldKeys.categoryId, references: BlogCategoryModel.schema, .id)
             .foreignKey(BlogPostModel.FieldKeys.authorId, references: BlogAuthorModel.schema, .id)
             .create(),
    
  2. StaticPageMigration_v1_0_0

     db.schema(StaticPageModel.schema)
         .id()
         .field(StaticPageModel.FieldKeys.title, .string, .required)
         .field(StaticPageModel.FieldKeys.**content, .data** )
         .create()
    

Wrong password provided in newest version

Hi, I just try to start the app form step by step tutorial form readMe and I found that you provide wrong password for user in text is FeatherCMS but that password don't work. But I found password in tests Feather and that one works.

Thank you and good work.

make install error

when using make install in a clean codebase.

for f in Sources/App/Modules/*; do  m=$(basename $f); cp -r "${f}/Views/" "Resources/Views/${m}" ; done;
cp: Resources/Views/Admin: No such file or directory
cp: Sources/App/Modules/Admin/Views/: unable to copy extended attributes to Resources/Views/Admin: No such file or directory
cp: Resources/Views/Admin/Actions.html: No such file or directory
cp: Resources/Views/Admin/Form.html: No such file or directory
cp: Resources/Views/Admin/Index.html: No such file or directory
cp: Resources/Views/Admin/Home.html: No such file or directory
cp: Resources/Views/Admin/Pager.html: No such file or directory
cp: Resources/Views/Admin/Table.html: No such file or directory
cp: Resources/Views/Admin/FormFields: No such file or directory
cp: Sources/App/Modules/Admin/Views//FormFields: unable to copy extended attributes to Resources/Views/Admin/FormFields: No such file or directory
cp: Resources/Views/Admin/FormFields/Select.html: No such file or directory
cp: Resources/Views/Admin/FormFields/Textarea.html: No such file or directory
cp: Resources/Views/Admin/FormFields/File.html: No such file or directory
cp: Resources/Views/Admin/FormFields/Input.html: No such file or directory
cp: Sources/App/Modules/Api/Views/: No such file or directory
cp: Resources/Views/Blog: No such file or directory
cp: Sources/App/Modules/Blog/Views/: unable to copy extended attributes to Resources/Views/Blog: No such file or directory
cp: Resources/Views/Blog/.DS_Store: No such file or directory
cp: Resources/Views/Blog/Frontend: No such file or directory
cp: Sources/App/Modules/Blog/Views//Frontend: unable to copy extended attributes to Resources/Views/Blog/Frontend: No such file or directory
cp: Resources/Views/Blog/Frontend/Post.html: No such file or directory
cp: Resources/Views/Blog/Frontend/Home.html: No such file or directory
cp: Resources/Views/Blog/Frontend/Posts.html: No such file or directory
cp: Resources/Views/Blog/Frontend/Category.html: No such file or directory
cp: Resources/Views/Blog/Frontend/Author.html: No such file or directory
cp: Resources/Views/Blog/Frontend/Authors.html: No such file or directory
cp: Resources/Views/Blog/Frontend/Categories.html: No such file or directory
cp: Resources/Views/Blog/Admin: No such file or directory
cp: Sources/App/Modules/Blog/Views//Admin: unable to copy extended attributes to Resources/Views/Blog/Admin: No such file or directory
cp: Resources/Views/Blog/Admin/Posts: No such file or directory
cp: Sources/App/Modules/Blog/Views//Admin/Posts: unable to copy extended attributes to Resources/Views/Blog/Admin/Posts: No such file or directory
cp: Resources/Views/Blog/Admin/Posts/List.html: No such file or directory
cp: Resources/Views/Blog/Admin/Posts/Edit.html: No such file or directory
cp: Resources/Views/Blog/Admin/Authors: No such file or directory
cp: Sources/App/Modules/Blog/Views//Admin/Authors: unable to copy extended attributes to Resources/Views/Blog/Admin/Authors: No such file or directory
cp: Resources/Views/Blog/Admin/Authors/List.html: No such file or directory
cp: Resources/Views/Blog/Admin/Authors/Edit.html: No such file or directory
cp: Resources/Views/Blog/Admin/Links: No such file or directory
cp: Sources/App/Modules/Blog/Views//Admin/Links: unable to copy extended attributes to Resources/Views/Blog/Admin/Links: No such file or directory
cp: Resources/Views/Blog/Admin/Links/List.html: No such file or directory
cp: Resources/Views/Blog/Admin/Links/Edit.html: No such file or directory
cp: Resources/Views/Blog/Admin/Categories: No such file or directory
cp: Sources/App/Modules/Blog/Views//Admin/Categories: unable to copy extended attributes to Resources/Views/Blog/Admin/Categories: No such file or directory
cp: Resources/Views/Blog/Admin/Categories/List.html: No such file or directory
cp: Resources/Views/Blog/Admin/Categories/Edit.html: No such file or directory
cp: Resources/Views/Frontend: No such file or directory
cp: Sources/App/Modules/Frontend/Views/: unable to copy extended attributes to Resources/Views/Frontend: No such file or directory
cp: Resources/Views/Frontend/Index.html: No such file or directory
cp: Resources/Views/Frontend/Pager.html: No such file or directory
cp: Resources/Views/Frontend/Sitemap.html: No such file or directory
cp: Resources/Views/Frontend/NotFound.html: No such file or directory
cp: Resources/Views/Frontend/Admin: No such file or directory
cp: Sources/App/Modules/Frontend/Views//Admin: unable to copy extended attributes to Resources/Views/Frontend/Admin: No such file or directory
cp: Resources/Views/Frontend/Admin/Contents: No such file or directory
cp: Sources/App/Modules/Frontend/Views//Admin/Contents: unable to copy extended attributes to Resources/Views/Frontend/Admin/Contents: No such file or directory
cp: Resources/Views/Frontend/Admin/Contents/List.html: No such file or directory
cp: Resources/Views/Frontend/Admin/Contents/Edit.html: No such file or directory
cp: Resources/Views/Frontend/Rss.html: No such file or directory
cp: Sources/App/Modules/Markdown/Views/: No such file or directory
cp: Resources/Views/Redirect: No such file or directory
cp: Sources/App/Modules/Redirect/Views/: unable to copy extended attributes to Resources/Views/Redirect: No such file or directory
cp: Resources/Views/Redirect/Admin: No such file or directory
cp: Sources/App/Modules/Redirect/Views//Admin: unable to copy extended attributes to Resources/Views/Redirect/Admin: No such file or directory
cp: Resources/Views/Redirect/Admin/Redirects: No such file or directory
cp: Sources/App/Modules/Redirect/Views//Admin/Redirects: unable to copy extended attributes to Resources/Views/Redirect/Admin/Redirects: No such file or directory
cp: Resources/Views/Redirect/Admin/Redirects/List.html: No such file or directory
cp: Resources/Views/Redirect/Admin/Redirects/Edit.html: No such file or directory
cp: Sources/App/Modules/Splash/Views/: No such file or directory
cp: Resources/Views/Sponsor: No such file or directory
cp: Sources/App/Modules/Sponsor/Views/: unable to copy extended attributes to Resources/Views/Sponsor: No such file or directory
cp: Resources/Views/Sponsor/Box.html: No such file or directory
cp: Resources/Views/Static: No such file or directory
cp: Sources/App/Modules/Static/Views/: unable to copy extended attributes to Resources/Views/Static: No such file or directory
cp: Resources/Views/Static/.DS_Store: No such file or directory
cp: Resources/Views/Static/Frontend: No such file or directory
cp: Sources/App/Modules/Static/Views//Frontend: unable to copy extended attributes to Resources/Views/Static/Frontend: No such file or directory
cp: Resources/Views/Static/Frontend/Page.html: No such file or directory
cp: Resources/Views/Static/Admin: No such file or directory
cp: Sources/App/Modules/Static/Views//Admin: unable to copy extended attributes to Resources/Views/Static/Admin: No such file or directory
cp: Resources/Views/Static/Admin/Pages: No such file or directory
cp: Sources/App/Modules/Static/Views//Admin/Pages: unable to copy extended attributes to Resources/Views/Static/Admin/Pages: No such file or directory
cp: Resources/Views/Static/Admin/Pages/List.html: No such file or directory
cp: Resources/Views/Static/Admin/Pages/Edit.html: No such file or directory
cp: Resources/Views/System: No such file or directory
cp: Sources/App/Modules/System/Views/: unable to copy extended attributes to Resources/Views/System: No such file or directory
cp: Resources/Views/System/Admin: No such file or directory
cp: Sources/App/Modules/System/Views//Admin: unable to copy extended attributes to Resources/Views/System/Admin: No such file or directory
cp: Resources/Views/System/Admin/Variables: No such file or directory
cp: Sources/App/Modules/System/Views//Admin/Variables: unable to copy extended attributes to Resources/Views/System/Admin/Variables: No such file or directory
cp: Resources/Views/System/Admin/Variables/List.html: No such file or directory
cp: Resources/Views/System/Admin/Variables/Edit.html: No such file or directory
cp: Resources/Views/User: No such file or directory
cp: Sources/App/Modules/User/Views/: unable to copy extended attributes to Resources/Views/User: No such file or directory
cp: Resources/Views/User/Frontend: No such file or directory
cp: Sources/App/Modules/User/Views//Frontend: unable to copy extended attributes to Resources/Views/User/Frontend: No such file or directory
cp: Resources/Views/User/Frontend/Login.html: No such file or directory
cp: Resources/Views/User/Admin: No such file or directory
cp: Sources/App/Modules/User/Views//Admin: unable to copy extended attributes to Resources/Views/User/Admin: No such file or directory
cp: Resources/Views/User/Admin/Users: No such file or directory
cp: Sources/App/Modules/User/Views//Admin/Users: unable to copy extended attributes to Resources/Views/User/Admin/Users: No such file or directory
cp: Resources/Views/User/Admin/Users/List.html: No such file or directory
cp: Resources/Views/User/Admin/Users/Edit.html: No such file or directory
make: *** [views] Error 1

I solved by including a mkdir "Resources/Views" in Makefile

views:
	mkdir "Resources/Views"
	for f in Sources/App/Modules/*; do  m=$$(basename $$f); cp -r "$${f}/Views/" "Resources/Views/$${m}" 2>/dev/null; done;

But maybe a better solution should be thinkered :)

Release build error

When I try to swift build --configuration release on both MacOS and Ubuntu I get this error:

/Users/ianapplebaum/Documents/github/feather/Sources/App/Extensions/Environment+FetchValue.swift:18:9: error: 'guard' body must not fall through, consider using a 'return' or 'throw' to exit the scope
        }
        ^

This doesn't show up when I do a normal build. Not sure what to make of this?
There is a precondition on the line the compiler is unhappy with saying

 precondition(false, """
                \(key) is not defined in the Environment.
                Check README.md or documentation for how to set environment variables.
                """)

I don't know why this would be an issue in the release configuration, but not the normal swift build or vapor build

LeafKit.LeafError.Reason.noTemplateExists("Blog/Frontend/Home"))

Not sure what happened. I've had Feather running for a while now on my server, just came back to it with the following errors...
Screen Shot 2020-11-18 at 10 45 40 PM
Screen Shot 2020-11-18 at 10 45 48 PM
I think my power got knocked out a while back so it could be as simple as a service not started but it seems as though Postgres is running so I don't think that's the issue... I'm just very stumped.

Suggestions and showcase

Showcase:
My first FEAHER CMS runs at http://gravato.aejm.pt (is still in the process of customization). Thanks to all.

Suggestions:

  • I need to translate "AUTHOR" to "Autor" in the post page: it would be great to have a variable for that.
  • the News module should be installed "out of the box".
  • a nice module for writing formulas and equations.

Doubts:

  • What is the best approach to include more figures in the posts?
  • How can change "Read Now" to "Ler agora"?
  • I added a new category "Liderança" that is not listed in the page Categories. What I'm missing?

Happy New Year to all.

Cannot edit metadata for my last post.

If I try to change the metadata for my last post, I have: {"reason":"Something went wrong.","error":true}.

If you wish, I can send you the credentials.

The logs:

gravato    | [ INFO ] GET /admin/frontend/metadatas/93668A47-3093-40C3-8DE1-33027526582B/update/ [request-id: A8493C74-2B1F-468E-A94B-7EEA7DDBACCF]
gravato    | [ ERROR ] Serializer.swift.evaluateScope():369
gravato    | TauKit: field.data is not a dictionary; field.data.options is invalid [request-id: A8493C74-2B1F-468E-A94B-7EEA7DDBACCF]
nginx_1    | ----- - [23/Apr/2021:13:39:06 +0000] "GET /admin/frontend/metadatas/93668A47-3093-40C3-8DE1-33027526582B/update/ HTTP/1.1" 500 47 "http://gravato.aena.pt/admin/blog/posts/FF08DA30-AFBD-4221-81A9-DDC73AACB0B8/update/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.0.3 Safari/605.1.15" "-"

Sponsor-module

Hi Tibor,
With my old docker file I try to run a old FeatherCMS version but now I found this error message: /opt/feather: error: unknown package 'sponsor-module' in dependencies of target 'Feather'. I tried to search for this module in the repository.No success! What happens? My CMS is now off. I have several articles in this blog, but now I am not able to run my CMS feather anymore. Please, if you can, or anybody can help, provide a solution for that. I'm using Feather CMS in a docker container.

Thanks a lot

Jorge

Can it be deployed directly?

If there is no additional development, can it be deployed directly?

dockerFile

# ================================
# Build image
# ================================
FROM swift:5.3-xenial as build

# Install OS updates and, if needed, sqlite3
RUN export DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true \
    && apt-get -q update \
    && apt-get -q dist-upgrade -y \
    && apt-get install -y libsqlite3-dev \
    && apt-get install -y zip \
    && rm -rf /var/lib/apt/lists/*

# Set up a build area
WORKDIR /build

# First just resolve dependencies.
# This creates a cached layer that can be reused
# as long as your Package.swift/Package.resolved
# files do not change.
COPY ./Package.* ./
RUN swift package resolve

# Copy entire repo into container
COPY . .

# Build everything, with optimizations and test discovery
RUN swift build --enable-test-discovery -c release

# Switch to the staging area
WORKDIR /staging

# Uncomment the next line if you need to load resources from the `Public` directory.
# Ensure that by default, neither the directory nor any of its contents are writable.
# 
RUN mv /build/Public ./Public && chmod -R a-w ./Public

# Copy main executable to staging area
# We copy all needed Swift runtime libraries into this folder as well.
# We do this by checking which libraries are needed at runtime with the ldd command and copy only those that have swift in the name.
RUN cp "$(swift build --package-path /build -c release --show-bin-path)/Run" ./ \
    && ldd ./Run | grep swift | awk '{print $3}' | xargs cp -Lv -t ./ \
    && ln -s "Run" "bootstrap" \
    && zip --symlinks lambda.zip *

shell

#!/bin/sh

# Build image
docker build -t vapor_one . -f Dockerfile.build
docker create --name extract vapor_one
docker cp extract:/staging ./app
docker rm -f extract

Is Feather CMS name available?

I recently created a cms project with your name. Trust me i didn't know this exist. The official name of my project is Feather CMS not Feather. Can i use that name?
I couldn't find your contact info sorry for asking it here.

Resolve bundle directory differences

When building Xcode the module bundle contains a Contents/Resources dir structure, but when using the command line, the bundle looks quite different. The contents are located directly under the bundle root.

Edit form save notifications in general

When the user saves a form it'd be nice to see some kind of visual feedback about what happened, instead of just reloading the page. The edit form notification box should be enabled by default for all the edit forms.

CSRF protection for forms

As a site admin
I want CSRF tokens on /admin routes
So that actions I take on the site are initiated only by me.
Unlike today when I could click a malicious link and unknowingly do admin actions like change email, password, and other site content.


I’d like to add the VaporCSRF library to admin actions.

Error on `swift run Feather`

On run command swift run Feather handle an error:

error: multiple products named 'Feather' in: 'feather-core', 'feather-main'
error: multiple targets named 'Feather' in: 'feather-core', 'feather-main'

Running Feather from Xcode causes error

Xcode Version 11.6 (11E708)

When running feather, any request results in the following error:

[ INFO ] GET / [request-id: 198CA90B-5B5A-458F-8C81-9EFE3F0B7480]
[ ERROR ] LeafError(file: "/Users/mcritz/Library/Developer/Xcode/DerivedData/feather-cngubcvrjcvskeejodbirpwuzeyd/SourcePackages/checkouts/leaf-kit/Sources/LeafKit/LeafSource/LeafSources.swift", function: "searchSources(t:on:s:)", line: 76, column: 69, reason: LeafKit.LeafError.Reason.noTemplateExists("Blog/Frontend/Home")) [request-id: 198CA90B-5B5A-458F-8C81-9EFE3F0B7480]

Add hints for the redirect edit form fields

It's not clear enough what to write into the source and destination fields.

Source -> Source (e.g. /path/)*
Destination -> Destination URL*

Validation?

  • check if source has leading & trailing slash?
  • check if destination is a valid url || has slashes?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.