Browse Source

Creating rake task to abstract docker development

Alax Alves 6 năm trước cách đây
mục cha
commit
4b64568b43
1 tập tin đã thay đổi với 7 bổ sung0 xóa
  1. 7 0
      Rakefile

+ 7 - 0
Rakefile

@@ -37,3 +37,10 @@ Rake::RDocTask.new do |rdoc|
   rdoc.rdoc_files.include('README*')
   rdoc.rdoc_files.include('lib/**/*.rb')
 end
+
+task :docker do
+  cmd = "docker-compose up -d && docker exec -i -t shopify_api bash" 
+  unless system(cmd, err: File::NULL)
+    abort "Something went wrong, do you have Docker and Docker-Compose installed?"
+  end
+end