Displaying 20 results from an estimated 20000 matches similar to: "Active Record w/ Stand Alone Script (no longer working?)"
2006 Oct 09
1
error running 'ruby script/console' => "uninitialized constant RAILS_ROOT" ??
Hi,
Anyone suggest why when I try to run the console via ''ruby script/console'' I
get the following "uninitialized constant RAILS_ROOT" ??
Error:
================================
V:\Source\testapp>ruby script\console
Loading development environment.
./script/../config/../config/environment.rb:3:NameError: uninitialized
constant RAILS_ROOT
2008 Apr 15
2
environment.rb uninitialized constant when starting console
I have the following code in environment.rb:
require File.join(File.dirname(__FILE__), ''boot'')
raw_config = File.read(RAILS_ROOT + "/config/config.yml")
APP_CONFIG = YAML.load(raw_config)[RAILS_ENV]
This works fine when running the server, but if I try and start a
console I get:
Loading development environment.
2007 May 09
0
Neophyte needs help!
Hi All,
Real neophyte here, to both backgroundrb and ruby/rails in general.
(Hey, we''ve all got to start somewhere, right!) :)
I''ve just been playing around with the example code at
http://backgroundrb.rubyforge.org/ , and trying to get all
the pieces to work (btw, I''m using version 0.2.1).
I did a ''generate worker example'', which created an
2009 May 11
3
daemons load activesupport 2.2.2 instead of 2.1.0, causing failure
Hi,
I have a couple of daemons that im trying to setup to be run for my
app. The environment load is as follows..
ENV["RAILS_ENV"] ||= "development"
require File.join(File.dirname(__FILE__), "/../../config/environment")
And the error I get is
#<LoadError: no such file to load -- active_support>
#<Gem::Exception: can''t activate activesupport (=
2006 Dec 06
0
Testing your workers
This has been asked before, never well attended perhaps.
Any thoughts on testing your workers?
Current implementation is broken. An empty test case like this:
require File.dirname(__FILE__) + ''/../test_helper''
require "#{RAILS_ROOT}/lib/workers/market_summary_worker"
require "#{RAILS_ROOT}/vendor/plugins/backgroundrb/lib/backgroundrb.rb"
require
2006 Jul 18
0
Rails Error w/ ActiveLdap
Hello,
I am working on creating a simple interface for an ldap user repository.
A little background, for development, I am working under Cygwin, with an
ssh port forward on port 636 (for SSL).
I have included clips of my error message and all
config/environment/model files below. I replaced domain information,
which I have double checked with "<CORRECT>".
Please let me know
2006 Jul 18
1
Rail w/ ActiveLdap
Hello,
I am working on creating a simple interface for an ldap user repository.
A little background, for development, I am working under Cygwin, with an
ssh port forward on port 636 (for SSL).
I have included clips of my error message and all
config/environment/model files below. I replaced domain information,
which I have double checked with "<CORRECT>".
Please let me know
2009 Apr 07
4
/lib daemon folder: how do i add a module into the daemon?
I am using the daemons plugin.
I have just one problem how do i add modules from the /lib folder to
the /lib/daemons/daemon.rb file
eg. /lib/basic_functions.rb
this is the file i want to load in daemon.rb
contents daemon.rb:
#!/usr/bin/env ruby
# You might want to change this
ENV["RAILS_ENV"] ||= "production"
require File.dirname(__FILE__) +
2007 Jun 21
0
Testing a Rails plugin
Hi
OK it looks like I''m a convert to BDD :-) Well in principle at least
- let''s see how it turns out.
I''ve just set up a test environment for the Hobo plugin according to
this guide:
http://www.pluginaweek.org/2006/11/24/plugin-tip-of-the-week-
testing-your-plugins-the-right-way/
And then adapted the setup to work with RSpec
In the plugin I now have:
/spec
2006 May 25
3
Behavior Change in Scripts since 1.1?
Occasionally we need to run scripts (such as from cron) that have access
to the rails environment.
Since we''ve upgraded to 1.1 (I believe it coincides with that), all of
our scripts seem to run as unit tests.
An example (obviously useless), which would be store in the script
directory:
------BEGIN CODE----------------------------
RAILS_ENV = ''development''
require
2007 Mar 19
0
action_web_services error with rspec_on_rails
I now have two specs in my rails project which correspond to one
rails controller. I can run them individually and they pass, but
running them together (either with the rake task just putting both
files on the command line):
euclid% spec spec/controllers/crud_resource_controller_spec.rb spec/
controllers/crud_resource_controller_with_join_models_spec.rb
2008 Mar 06
1
Unitialized constant ActionView::Helpers::TagHelper::Set
Hi all,
I write the following test to a simple plugin
require ''rubygems''
require ''test/unit''
require File.dirname(__FILE__) + ''/../lib/meta_tags''
require ''action_view/helpers/tag_helper''
class MetaTagsTest < Test::Unit::TestCase
include MetaTagHelper
include ActionView::Helpers::TagHelper
.
2011 Aug 09
0
Devise, RSpec and Webrat
My app is builded with rails 2.3.12, rspec-rails 1.3.2, webrat 0.7.3.
My spec_helper.rb
ENV["RAILS_ENV"] ||= ''test''
require
File.expand_path(File.join(File.dirname(__FILE__),''..'',''config'',''environment''))
require ''spec/autorun''
require ''spec/rails''
require
2009 May 12
0
`load_missing_constant': uninitialized constant Rails::Generator (NameError)
Hello,
I''m probably missing something pretty basic here as a rails newbie but
I''m trying to write a plugin and I am trying to get my generator to work.
I am trying to call the manifest method in my
vendor/plugins/media_module/generators/media_module_generator.rb from my
vendor/plugins/media_module/init.rb.
here''s the code in vendor/plugins/media_module/init.rb:
2006 Feb 01
3
apache2 / fcgi / RoR - no connection
Hi,
I''ve generated a new Rails app and dummy controller "foo" with method
"hello". I am trying to run it under Apache/2.0.53 with fastcgi, and
getting the index.html page when I hit http://localhost/foo/hello, or
for any other request (http://localhost/kdjfslkfjs). Also, there is
nothing in the rails logs, and no errors in the apache logs.
Relevant bit of
2012 Jun 21
2
Rails production load order giving uninitialized constant (NameError)
Hi,
I have a related but separate question. Again, please redirect me if I''m
in the wrong place.
I''ve been getting this error in production (on Heroku) only (it happens
when the application is loading):
2012-06-21T09:30:19+00:00 app[web.1]: /app/app/controllers/spree/
checkout_controller_decorator.rb:3:in `block in '': uninitialized constant
2007 Jul 18
1
DRb Server can not run!
I''m doing the next.
1, rails hecc
2, cd hecc
3, script/plugin install
svn://projects.jkraemer.net/acts_as_ferret/tags/stable/acts_as_ferret
4, RAILS_ENV=production
vendor/plugins/acts_as_ferret/script/ferret_start
vendor/plugins/acts_as_ferret/script/ferret_start:21:in `require'': no
such file to load -- vendor/plugins/acts_as_ferret/script/../config/boot
(LoadError)
2009 Jul 31
6
Background daemon
It''s sending e-mail every hour, but I changed to sleep for a day, but
keep send the e-mail by hour. I don''t know what to do to send daily.
Could somebody help me?
thanks
############
# mailer.rb
###############
#!/usr/bin/env ruby
# You might want to change this
ENV["RAILS_ENV"] ||= "production"
require File.dirname(__FILE__) +
2020 Sep 11
0
How to convert stand-alone samba servers to join existing Windows Active Directory domain
On 10/09/2020 20:28, Ted Buchanan via samba wrote:
> We have multiple stand-alone samba (4.2.10 and 4.10.4) file sharing
> servers with hundreds of local users on each server (not the same on all
> samba servers) in a CentOS/Oracle Linux (6 and 7) network. We would like
> to convert these stand-alone servers to join an existing Windows based AD
> domain without losing data or
2020 Sep 11
0
How to convert stand-alone samba servers to join existing Windows Active Directory domain
On 9/10/20 3:28 PM, Ted Buchanan via samba wrote:
> We have multiple stand-alone samba (4.2.10 and 4.10.4) file sharing
> servers with hundreds of local users on each server (not the same on all
> samba servers) in a CentOS/Oracle Linux (6 and 7) network. We would like
> to convert these stand-alone servers to join an existing Windows based AD
> domain without losing data or