start new:
tmux
start new with session name:
tmux new -s myname
Services declared as oneshot
are expected to take some action and exit immediatelly (thus, they are not really services,
no running processes remain). A common pattern for these type of service is to be defined by a setup and a teardown action.
Let's create a example foo
service that when started creates a file, and when stopped it deletes it.
Create executable file /opt/foo/setup-foo.sh
:
stats = Sidekiq::Stats.new | |
stats.queues | |
stats.enqueued | |
stats.processed | |
stats.failed |
GitHub supports several lightweight markup languages for documentation; the most popular ones (generally, not just at GitHub) are Markdown and reStructuredText. Markdown is sometimes considered easier to use, and is often preferred when the purpose is simply to generate HTML. On the other hand, reStructuredText is more extensible and powerful, with native support (not just embedded HTML) for tables, as well as things like automatic generation of tables of contents.
Byobu Commands | |
============== | |
byobu Screen manager | |
Level 0 Commands (Quick Start) | |
------------------------------ | |
<F2> Create a new window |
/* | |
To test that the Linux framebuffer is set up correctly, and that the device permissions | |
are correct, use the program below which opens the frame buffer and draws a gradient- | |
filled red square: | |
retrieved from: | |
Testing the Linux Framebuffer for Qtopia Core (qt4-x11-4.2.2) | |
http://cep.xor.aps.anl.gov/software/qt4-x11-4.2.2/qtopiacore-testingframebuffer.html | |
*/ |
# Instead of loading all of Rails, load the | |
# particular Rails dependencies we need | |
require 'sqlite3' | |
require 'active_record' | |
# Set up a database that resides in RAM | |
ActiveRecord::Base.establish_connection( | |
adapter: 'sqlite3', | |
database: ':memory:' | |
) |
If your master.key has been compromised, you might want to regenerate it.
No key regeneration feature at the moment. We have to do it manually.
rails credentials:show
somewhere temporarily.config/master.key
and config/credentials.yml.enc
EDITOR=vim rails credentials:edit
in the terminal: This command will create a new master.key
and credentials.yml.enc
if they do not exist.config/credentials.yml.enc