Move the go commands that should run under cmd/ipfs in the Makefile in
cmd/ipfs rather than doing a "cd cmd/ipfs && go ..." in the root
Makefile.
The "cd cmd/ipfs && go ..." lines causes problems with GNU Emacs's
compilation mode. With the current setup Emacs is unable to jump to
the location of the error outputted by go compiler as it can not find
the source file. The problem is that the embedded "cd" command causes
Emacs's compilation mode to lose track of the current directory and
thus attempts to look for the source file in the wrong directory.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
* Adds repo fsck subcommand
Fixes#2457
License: MIT
Signed-off-by: Mike Pfister <pfista@gmail.com>
* Checks for error on file deletion
License: MIT
Signed-off-by: Mike Pfister <pfista@gmail.com>
* Checks if node is online
License: MIT
Signed-off-by: Mike Pfister <pfista@gmail.com>
* Update error checking
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* Prevents command from running while daemon is running
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* Add newline to command output message
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* removing superfluous error
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* Adds sharness test for repo fsck command
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* Ignore warning if file doesn't exist
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* Updating message output
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* adding debug statements
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* update and add fsck sharness tests
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* updating comments
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* Use printf in test
Using printf prevents a newline from being printed to the api test file. When
the newline was present, multiaddr threw errors trying to parse the api address
to an integer since the newline character was present.
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* updating tests
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
* removing commented code
License: MIT
Signed-off-by: Michael Pfister <pfista@gmail.com>
With a proper IpfsCollector object and tests, this time.
The collector object makes it easy to add further metrics,
like e.g. bitswap wants/provs.
License: MIT
Signed-off-by: Lars Gierth <larsg@systemli.org>
The gateway accepts an X-Ipfs-Path-Prefix header,
and assumes that it is mounted in a reverse proxy
like nginx, at this path. Links in directory listings,
as well as trailing-slash redirects need to be rewritten
with that prefix in mind.
We don't want a potential attacker to be able to
pass in arbitrary path prefixes, which would end up
in redirects and directory listings, which is why
every prefix has to be explicitly allowed in the config.
Previously, we'd accept *any* X-Ipfs-Path-Prefix header.
Example:
We mount blog.ipfs.io (a dnslink page) at ipfs.io/blog.
nginx_ipfs.conf:
location /blog/ {
rewrite "^/blog(/.*)$" $1 break;
proxy_set_header Host blog.ipfs.io;
proxy_set_header X-Ipfs-Gateway-Prefix /blog;
proxy_pass http://127.0.0.1:8080;
}
.ipfs/config:
"Gateway": {
"PathPrefixes": ["/blog"],
// ...
},
dnslink:
> dig TXT _dnslink.blog.ipfs.io
dnslink=/ipfs/QmWcBjXPAEdhXDATV4ghUpkAonNBbiyFx1VmmHcQe9HEGd
License: MIT
Signed-off-by: Lars Gierth <larsg@systemli.org>
For the rest of the packages in util, move them to thirdparty
and update the references. util is gone!
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
This lets FUSE mounts to track whether they are active or not by
tracking when fs.Serve terminates.
License: MIT
Signed-off-by: Stephen Whitmore <noffle@ipfs.io>
misc/completion/ipfs-completion.bash: add `ipfs stats` to BASH completion
core/commands/mount_unix.go: ensure error is not nil before printing it
contribute.md: fix bibliography indexing in example
core/commands/swarm.go: change tabs to spaces in USAGE message
*: 80-column readability improvements
License: MIT
Signed-off-by: Thomas Gardner <tmg@fastmail.com>
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
rewrite path to filepath in fsrepo
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
remove api file on repo close
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
update function to check normal net.OpErrors
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>