Commit Graph

5 Commits

Author SHA1 Message Date
Kazuhiro MUSASHI dd167df1cf Change EC2 server IP Address. 2023-07-09 20:46:49 +09:00
Kazuhiro MUSASHI eee4ba7caf Make `Rake` task for production. 2023-01-15 21:49:32 +09:00
Kazuhiro MUSASHI 8beeed147f 画像をGit LFSの管理外に 2023-01-09 22:00:05 +09:00
Kazuhiro MUSASHI e2c08640d1 `prep.rake`と`staging.rake`の作成 2023-01-03 12:30:49 +09:00
Kazuhiro MUSASHI 6ab93a3d2d `hugo sever`用のタスクを追加
diff --git a/Rakefile b/Rakefile
new file mode 100644
index 0000000..99233bd
--- /dev/null
+++ b/Rakefile
@@ -0,0 +1,3 @@
+#!/usr/bin/env rake
+
+Dir['tasks/**/*.rake'].each { |path| load path }
diff --git a/tasks/demo.rake b/tasks/demo.rake
new file mode 100755
index 0000000..d10863b
--- /dev/null
+++ b/tasks/demo.rake
@@ -0,0 +1,12 @@
+#!/usr/bin/env rake
+
+require 'socket'
+
+desc 'Generate the HTML demo pages including drafts'
+task :demo do
+  ip = Socket.getifaddrs.select{|x|
+    x.name == "ens160" and x.addr.ipv4?
+  }.first.addr.ip_address
+
+  sh "hugo server --buildDrafts -w --bind #{ip} -b #{ip} --disableFastRender"
+end
2023-01-01 10:21:24 +09:00