【发布时间】:2019-12-14 21:35:26
【问题描述】:
我正在尝试在我的 public/blog 目录中设置 jekyll 博客。
对于这个问题,假设我只想让public/blog 目录与index.html 和css/site.css 与此页面的css。
我正在使用 capistrano 部署它,所以我将 public/blog 添加到 linked_dirs
index.html:
<html>
<head>
<link rel="stylesheet" type="text/css" href="css/site.css">
</head>
<body>
<h1>Hello World</h1>
</body>
</html>
css/site.css:
h1 {
color: red;
}
现在cap production deploy 之后我可以访问domain.com/blog 并看到Hello World 标头,但它不会加载css 文件。
我收到Failed to load resource: the server responded with a status of 404 (Not Found) 错误。
你知道我怎样才能让它工作吗?
【问题讨论】:
标签: ruby-on-rails ruby-on-rails-5 capistrano