我正在为一个新的工作场所开发一个新服务器,我正在尝试重用我今年早些时候在Python中编写的CGI脚本.我的CGI脚本开始于
#!/local/usr/bin/python
Run Code Online (Sandbox Code Playgroud)
但是当我在新服务器上运行它时,它会抱怨没有这样的文件夹.显然Python在这个盒子上保存在不同的位置,但我不知道在哪里.
我之前没有做过很多unix,只是足以绕过,所以如果有一些巧妙的技巧我应该知道在这里我会很感激:)
谢谢!
我正在尝试在运行时构建一些过滤器,这些过滤器可以应用于表tunnel或tunnel LEFT OUTER JOIN connection ON (tunnel.id = connection.tunnel_id).
这些表的定义如下:
// Define the tunnel table and struct
table! {
#[allow(unused_imports)]
use diesel::sql_types::*;
tunnel (id) {
id -> BigInt,
name -> Text,
}
}
#[derive(Queryable, Identifiable, Clone, Debug, PartialEq, Eq)]
#[table_name = "tunnel"]
pub struct Tunnel {
pub id: i64,
pub name: String,
}
// Define the connection table and struct
table! {
#[allow(unused_imports)]
use diesel::sql_types::*;
connection(id) {
id -> BigInt,
tunnel_id -> BigInt,
}
}
#[derive(Debug, …Run Code Online (Sandbox Code Playgroud)