Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

A lightweight script and log management tool for DevOps

Notifications You must be signed in to change notification settings

codefirst/sunline

Repository files navigation

Sunline

Deploy

Install

Install dependencies:

$ bundle install --without development test
$ bin/yarn

Precompile assets:

$ bin/rails assets:precompile RAILS_ENV=production

Setup database:

$ bin/rails db:migrate RAILS_ENV=production

S3 settings

if you use S3 as storage, set several environment variables.

$ export ACTIVE_STORAGE_SERVICE=amazon
$ export AWS_BUCKET=bucket name
$ export AWS_ACCESS_KEY_ID=access key
$ export AWS_SECRET_ACCESS_KEY=secret access key
$ export AWS_REGION=ap-northeast-1

Slack integration

if you want to notify logs to a Slack channel.

$ export SLACK_WEBHOOK_URL=https://hooks.slack.com/services/xxx/yyy/zzz

Run:

$ export OMNIAUTH_GITHUB_CLIENT_ID=Client ID
$ export OMNIAUTH_GITHUB_CLIENT_SECRET=Client Secret
$ export OMNIAUTH_GITHUB_ORGANIZATION=Some Organization # optional
$ bin/rails s -e production

and access to http://localhost:3000/

For developers

Setup database:

$ bin/rails db:migrate RAILS_ENV=test

Run server:

$ bin/dev

Run tests:

$ bin/rails spec

Run docker:

$ docker build -t sunline .
$ docker run -p 3000:3000 -e DATABASE_URL="postgresql://user:pass@localhost:5432/sunline_production?host=host.docker.internal" -e RAILS_FORCE_SSL=false -e RAILS_SERVE_STATIC_FILES=true -e OMNIAUTH_GITHUB_CLIENT_ID=xxx -e OMNIAUTH_GITHUB_CLIENT_SECRET=xxx sunline

About

A lightweight script and log management tool for DevOps

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

AltStyle によって変換されたページ (->オリジナル) /