Answers.Body: <p>The other error Im getting is <code>dirname: command not found</code>.</p>
  <p>I was able to solve this issue by just manually setting the DIR variable in the script I needed to use. There is probably a better way....</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-05-21T18:55:30.497Z
Answers.LastActivityDate: 2021-05-21T18:55:30.497Z
Answers.UserDisplayName: Document Services
Body: <p>I'm having trouble setting the variables of the env.sh file for craft-sctipts.</p>
  <p>I getting an error: <code>File /common/defaults.sh is missing, aborting.</code> when I try to clear the cache using a cronjob pointing to the clear cache script.</p>
  <p>My variables are set in the env.sh file, which is in the scripts directory.
  <code>LOCAL_ROOT_PATH=&quot;/domains/mydomain.ca/&quot;</code>
  <code>REMOTE_ROOT_PATH=&quot;/domains/mydomain.ca/&quot;</code></p>
  <p>The scripts are in <code>/domains/mydomain.ca/scripts/</code> directory.</p>
  <p>Any thoughts?</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-05-15T14:44:21.277Z
Comments.Text: Those root paths aren't relative to your project root, they are meant to be absolute system paths - are the `/domains` folders at the root of your system?
Comments.UserDisplayName: michaelroper
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-05-21T18:13:09.450Z
Comments.Text: Yah... /domains is the top level directory (Shared Media Temple hosting).
Comments.UserDisplayName: Document Services
Tags: <cache>
Title: .env.sh in craft-scrips
ThreadText: # .env.sh in craft-scrips
  
  (Asked by: username_0 on 2021-05-14)
  
  I'm having trouble setting the variables of the env.sh file for craft-sctipts.
  
  I getting an error: `File /common/defaults.sh is missing, aborting.` when I try to clear the cache using a cronjob pointing to the clear cache script.
  
  My variables are set in the env.sh file, which is in the scripts directory.
  `LOCAL_ROOT_PATH="/domains/mydomain.ca/"`
  `REMOTE_ROOT_PATH="/domains/mydomain.ca/"`
  
  The scripts are in `/domains/mydomain.ca/scripts/` directory.
  
  Any thoughts?
  
  **Tags:** cache
  
  > **Comments:**
  > **username_1**: Those root paths aren't relative to your project root, they are meant to be absolute system paths - are the `/domains` folders at the root of your system?  
  > **username_0**: Yah... /domains is the top level directory (Shared Media Temple hosting).  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_0 on 2021-05-21. Score: 1
  
  The other error Im getting is `dirname: command not found`.
  
  I was able to solve this issue by just manually setting the DIR variable in the script I needed to use. There is probably a better way....
  
  
  ---
  
  