<p>I'm trying to migrate from Delayed_Job to Sidekiq. and by running Sidekiq in kubernetes an unrecognised error comes to surface:</p>
<pre><code>==================================================================
  Please point Sidekiq to a Rails application or a Ruby file  
  to load your job classes with -r [DIR|FILE].
==================================================================
</code></pre>
<p>Kubernetes deployment snippet:</p>
<pre><code>      ...
      containers:
        - name: sidekiq
          image: {{ application_registry }}
          imagePullPolicy: Always
          command:
            - bundle
          args:
            - exec
            - sidekiq
            - -r # not included in the original setting.
            - /app/config/application.rb # not included in the original setting.
            - &quot;-C&quot;
            - &quot;/app/config/sidekiq.yml&quot;
          resources:
            ...
</code></pre>
<p>PS: A lot of existing jobs still lay on DelayJob, some we plan to progressively migrate. so we include Sidekiq per job not globally:</p>
<pre><code>class FirstJob &lt; ApplicationJob
      self.queue_adapter = :sidekiq

      ...
</code></pre>
<p>Following some guides described <a href="https://stackoverflow.com/a/19339758/6589296">Here</a>. I tried to require the <code>config/application.rb</code> under the <code>-r</code> flag, but nothing fixed.</p>

Sebri Issam
<p>Get rid of</p>
<pre><code>        - -r # not included in the original setting.
        - /app/config/application.rb # not included in the original setting.
        - &quot;-C&quot;
        - &quot;/app/config/sidekiq.yml&quot;
</code></pre>
<p>You need to set the current working directory to /app.</p>
