mirror of
https://github.com/actix/actix-website
synced 2024-11-27 10:02:57 +01:00
Cargo can't do nested workspaces.
This commit is contained in:
parent
e43f408bce
commit
315b131cdd
@ -1,8 +1,12 @@
|
||||
[workspace]
|
||||
members = [
|
||||
"application",
|
||||
"front-page",
|
||||
"easy-form-handling",
|
||||
"flexible-responders",
|
||||
"getting-started",
|
||||
"main-example",
|
||||
"powerful-extractors",
|
||||
"request-routing",
|
||||
"server",
|
||||
"url-dispatch",
|
||||
]
|
||||
|
@ -27,8 +27,8 @@ fn main() {
|
||||
.route("/", web::get().to(index))
|
||||
.route("/register", web::post().to(register))
|
||||
})
|
||||
.bind("127.0.0.1:8000")
|
||||
.expect("Can not bind to port 8000")
|
||||
.bind("127.0.0.1:8088")
|
||||
.unwrap()
|
||||
.run()
|
||||
.unwrap();
|
||||
}
|
@ -6,7 +6,7 @@
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h3>Will hit handle_post_1</h3>
|
||||
<h3>Its a form.</h3>
|
||||
|
||||
<form action=/register method=POST>
|
||||
|
@ -21,8 +21,8 @@ fn main() {
|
||||
.service(web::resource("/").to(hello_world))
|
||||
.service(web::resource("/temp").to(current_temperature))
|
||||
})
|
||||
.bind("127.0.0.1:8000")
|
||||
.expect("Can not bind to port 8000")
|
||||
.bind("127.0.0.1:8088")
|
||||
.unwrap()
|
||||
.run()
|
||||
.unwrap();
|
||||
}
|
@ -1,8 +0,0 @@
|
||||
[workspace]
|
||||
members = [
|
||||
"main-example",
|
||||
"flexible-responders",
|
||||
"easy-form-handling",
|
||||
"request-routing",
|
||||
"powerful-extractors",
|
||||
]
|
@ -1,5 +1,5 @@
|
||||
[package]
|
||||
name = "front-page"
|
||||
name = "main-example"
|
||||
version = "0.1.0"
|
||||
edition = "2018"
|
||||
|
@ -12,8 +12,8 @@ fn main() {
|
||||
.service(web::resource("/").to(greet))
|
||||
.service(web::resource("/{name}").to(greet))
|
||||
})
|
||||
.bind("127.0.0.1:8000")
|
||||
.expect("Can not bind to port 8000")
|
||||
.bind("127.0.0.1:8088")
|
||||
.unwrap()
|
||||
.run()
|
||||
.unwrap();
|
||||
}
|
@ -37,8 +37,8 @@ fn main() {
|
||||
.route("/", web::get().to(index))
|
||||
.route("/event", web::post().to(capture_event))
|
||||
})
|
||||
.bind("127.0.0.1:8000")
|
||||
.expect("Can not bind to port 8000")
|
||||
.bind("127.0.0.1:8088")
|
||||
.unwrap()
|
||||
.run()
|
||||
.unwrap();
|
||||
}
|
@ -18,7 +18,7 @@
|
||||
}
|
||||
|
||||
function submitJson() {
|
||||
fetch('http://localhost:8000/event', {
|
||||
fetch('http://localhost:8088/event', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Accept': 'application/json',
|
@ -15,7 +15,7 @@ fn main() {
|
||||
.service(web::resource("/").to(index))
|
||||
.service(web::resource("/{name}").to(hello))
|
||||
})
|
||||
.bind("127.0.0.1:8000")
|
||||
.bind("127.0.0.1:8088")
|
||||
.unwrap()
|
||||
.run()
|
||||
.unwrap();
|
Loading…
Reference in New Issue
Block a user