Commit Graph

184 Commits

Author SHA1 Message Date
mpl 3f24764ea9 make.go: update to Go 1.11 as required version
Wich also means updating github.com/gopherjs/gopherjs to
rev 0210a2f0f73c96103378b0b935f39868e5731809

Fixes #1211

Change-Id: I9ae580bffda523237d471942f39ae157ff4bd303
2018-09-14 13:01:08 +00:00
mpl 022e7ddd80 make.go: build embeds for keepy
Forgot to add that change to ba5aa9d3b9

Change-Id: I6a83c9f5a651d3bf629d1a734faee24399839dd6
2018-07-20 02:39:52 +02:00
mpl 8b40fb83fe make.go: add with_embed build tag to all generated resources
And then build targets with with_embed only if embed_static command-line
flag is true.

Fixes #1157

Change-Id: If6a998749e0caae5ee21037d667bcc476562a354
2018-05-15 20:14:50 +02:00
mpl 6a04db2f5d misc/docker: make release tools work with latest version mechanism
Change-Id: Id2081c2f0047621fa929baeba684de219eb869ff
2018-05-02 19:04:40 -07:00
Brad Fitzpatrick 46bb719dc5 buildinfo: track Version and Dockerfile separately
And don't hard-code VERSION info in the Dockerfile.

Change-Id: I35cb22fbb56cd634be4f1342c54ca86ce0e79901
2018-05-02 13:36:32 -07:00
Brad Fitzpatrick 12894d4630 all: Windows fixes (don't listen on file descriptors in test.World, etc)
test/integration: don't listen on file descriptors.
make.go: unrelated, but options to make it much faster.
internal/images: t.Skip on HEIC dependency failures

Fixes #1140
Updates golang/go#25210

Change-Id: I8092155411826d6ed1f8d85230b753d1369044af
2018-05-01 21:38:19 -07:00
mpl 2286b6442b website: move go code to pk-web package
Fixes #1109

Change-Id: Ibcba1addf25da414f4d9cb42f621d6b9184898da
2018-04-23 16:42:35 -07:00
Brad Fitzpatrick b5392b7d3b Merge "make.go: validate that make.go is run in GOPATH" 2018-04-23 03:57:55 +00:00
mpl 7a27eb42eb cmd: rename camget to pk-get, and make it a mode of pk
A couple of related fixes and renames too.

Updates #981
Fixes #1056

Change-Id: Id47a933c77422edfb9db41d34c38ed9d0d7a1846
2018-04-22 20:50:54 -07:00
Brad Fitzpatrick 05684c3dc1 make.go: validate that make.go is run in GOPATH
It used to be a feature of make.go that it could run from anywhere and
users could ignore GOPATH. We would still like that, but the
shenanigans we did before to mirror the perkeep source tree to a temp
directory and set GOPATH to that temp directory were annoying. And
fortunately GOPATH is slowly dying, so we won't need to deal with this
forever. As of Go 1.8, there is always now a default GOPATH
(https://golang.org/doc/go1.8#gopath), so at least people don't need
to set environment variables. And in Go 1.12-ish, we'll probably ditch
GOPATH entirely.

So, for now require that users build in their GOPATH, which might be
the implicit GOPATH if they haven't set one. This only affects
developers. Regular users can use release binaries.

Change-Id: Ib4e3f05fa987baeaba5aa51349887e6c243f0092
2018-04-22 20:16:51 -07:00
mpl b27ac3a71b make.go: use first value of GOPATH
Fixes #1101

Change-Id: Ia6993d81f93b8aa64582d1b265d094fc7b232fc7
2018-04-22 11:05:27 -07:00
mpl 9035ba9f25 make.go: fix cross compilation
When installing, respect user defined GOBIN and/or GOPATH, or the
Go defaults.
But when cross-compiling, disable GOBIN, as it's not supported.

Fixes #1100

Change-Id: I69485722d6dbfcbf7721463077f828efc950d9d3
2018-04-21 21:44:05 +02:00
Brad Fitzpatrick ca76a40bbc Rename camlistored to perkeepd.
Updates #981

Change-Id: I8fe43c240c149074c23128a89ab426af9cbf94b4
2018-04-21 11:06:09 -07:00
mpl ce4658abfc cmd: rename camput to pk-put, and make "pk put" call it
A new "put" mode is added to the pk command, so that the "pk put"
command can be used to create and upload blobs.

What this command does is actually just call the previously named
"camput" executable, which is renamed to "pk-put" in this change.

This involves adding a new way to register a mode in cmdmain, when such
a mode is just meant to call an external binary. To emphasize the
distinction, the existing func (to register a sub-command, or a mode) is
renamed from RegisterCommand to RegisterMode, and RegisterCommand is now
the name of the new func/way.

Updates #981
Updates #1056

Change-Id: Ief954c17aa88a376f551df7de4b4e9fe41ad96d1
2018-04-21 10:26:55 -07:00
Tilman Dilo 4eff07253a make.go: handle genfileembed stderr output again
Due to a regression introduced in f8ef262f, the stderr output of
genfileembed was not handled anymore. This caused the build to hang on
Windows systems.

This change introduces a buffer to contain all of genfileembed's stderr
output (usually a long list of files). The buffer's contents are printed
when the command fails to run successfully or when verbose build mode is
enabled. Running of the command is simplified by just calling Run()
instead of Start() and Wait(). The -output-files-stderr flag for
genfileembed, obsolete since f8ef262f, is removed.

Fixes #1099

Change-Id: Ibd8a124c73bf347b92acfc85fffd1186dfe4944b
2018-04-19 19:34:42 +02:00
Brad Fitzpatrick c193a87ae1 make.go: don't fail to build gopherjs if it doesn't already exist
Fixes #1096

Change-Id: I71c3a48248503b94ef0b4415083ccf95b5bb6265
2018-04-17 13:31:33 -07:00
mpl f8ef262ff9 make.go: clean up, notably remove the tmp source code mirroring
Fixes #1004

Change-Id: Iea01cfc601b8dd8f2a81fe5da40cdd272b164bb1
2018-04-17 19:39:46 +02:00
Eric Drechsel e4903de21b vendor: update gopherjs to 82b322028c96512b15077093b16a5f1c7ea897ac
Change-Id: I19128ea01fad41267eaf870e57e799388123c3fb
2018-04-03 17:08:44 -07:00
Attila Tajti 0b4e282f9b make.go: fixes for building on windows
Replace exeName() with functions runtimeExeName() and buildExeName().

runtimeExeName() returns the executable name on the OS
make.go itself is running on.

buildExeName() returns the executable name on the build (target) OS.

Change-Id: I50b17e3991477d7507f4cb4c6f7676190182ddbd
2018-03-19 18:50:29 +01:00
Mathieu Lonjaret 7fe1438341 Merge "make.go: fix format verb for printing Go version" 2018-03-10 20:43:56 +00:00
Max Bernstein 8ebb65beb2 make.go: fix format verb for printing Go version
Change-Id: I067ab592bbc0fc76155c791103d7a59443bb9454
2018-03-10 21:42:34 +01:00
mpl 6dcbe2ee9c cmd/camtool: rename from camtool to pk
Updates #981
Updates #1056

Change-Id: Ib78c47a69fa9816d5ac6cc547586a2af321005e3
2018-03-06 16:20:59 +01:00
mpl 1c69fb09da make.go: try harder to find gopherjsGoroot
And log what version of Go they have, to help us debug.

Issue #935

Change-Id: I852efeae65054e1c5f8032d9b3321c615a1b5b39
2018-02-26 18:31:48 +01:00
mpl 0684ad466f make.go: rollback to Go 1.9 as the default
Go 1.10 for Perkeep and Go 1.9 for GopherJS as requirements is apparently
not explained well enough by the error message. So until we improve on
that, it's better to keep both requirements at the same version.
And we can update both soon to 1.10 when GopherJS supports 1.10 too.

Change-Id: I9f015dd27c18abad0b48559f2f40aa44362b000a
2018-02-25 20:57:56 +01:00
mpl 2681557121 make.go: make Go 1.10 the default
Updates #1004

Change-Id: I68bf2deddecee46ce2fef6194019381b3e147afd
2018-02-23 20:07:47 +01:00
Paul Lindner f3839bcc8f Update make.go to support versions greater than 9
The current go version checks in make.go assume a single character
minor version number.  This change switches the constants to integers
instead of characters and uses a regex to check for versions.

Updates #1004

Change-Id: I7df14b69447119ecfa8379453f5c7022f20d6b5e
2018-02-20 06:03:19 +00:00
Paul Lindner 5894af5196 vendor: upgrade to a versioned dep of sqlite
Use the now renamed libsqlite3 build pragma. This requires
having sqlite3 installed on the system instead of using the
c code bundled in vendor (which is removed by the dep tool
by default)

1.6.0 corresponds with rev
github.com/mattn/go-sqlite3@6c771bb9887719704b210e87e934f08be014bdb1

Changelog: See https://github.com/mattn/go-sqlite3/releases

Change-Id: I48fc0bc005715b83805837f544e7fa7875e6d56a
2018-02-12 09:42:29 -08:00
Paul Lindner 463832ed76 clients/web/embed: Move vendor/embed to clients/web/embed and adjust paths
Addresses #889
Fixes #1024

Change-Id: I9fa1dc246b0a3a1a4e4ec7abab0a7828fdfdb41e
2018-01-09 22:33:03 +00:00
Brad Fitzpatrick 617ac40512 all: rename cammount to pk-mount
Updates #981

Change-Id: Ie1d2e3c0fd7e2b7a7801ceac0fd8f93f62d56651
2018-01-08 09:54:41 -08:00
Brad Fitzpatrick 9265c980de all: change github.com/camlistore/camlistore to github.com/perkeep/perkeep
Change-Id: I0d612bf450e9e8d9ce0767c5a0cb0c44c0d8704f
2018-01-05 19:49:59 -08:00
mpl 478d85457f make.go: mirror internal for website and camnetdns too
Change-Id: I118244058d0da2cd2b7e56d8e226b178c197c2f8
2018-01-05 20:14:34 +01:00
Brad Fitzpatrick 57648c6b83 all: update copyright holder from Google Inc to The Perkeep Authors
The AUTHORS file is the list of copyright holders.
2018-01-03 16:52:49 -08:00
Brad Fitzpatrick 8a0a3e8649 Rename camdeploy to pk-deploy.
Updates #981

Change-Id: I4c6c16135f3239bb4b8d2d187e9537a4abf7a3fe
2018-01-02 22:10:37 -08:00
Brad Fitzpatrick b1f2de212c make.go: remove redundant failure message I forgot to delete
Change-Id: Ia81f14ee958d49d53e5ef8961f77518e6a4c6802
2018-01-01 17:27:42 -08:00
Brad Fitzpatrick dd199eb0cb make.go: fail if in camlistore.org directory, help user
Change-Id: Ie8bdc88d79c945968832169e942eedc58debdc1e
2018-01-01 17:16:18 -08:00
Brad Fitzpatrick d6a0b05df0 Rename import paths from camlistore.org to perkeep.org.
Part of the project renaming, issue #981.

After this, users will need to mv their $GOPATH/src/camlistore.org to
$GOPATH/src/perkeep.org. Sorry.

This doesn't yet rename the tools like camlistored, camput, camget,
camtool, etc.

Also, this only moves the lru package to internal. More will move to
internal later.

Also, this doesn't yet remove the "/pkg/" directory. That'll likely
happen later.

This updates some docs, but not all.

devcam test now passes again, even with Go 1.10 (which requires vet
checks are clean too). So a bunch of vet tests are fixed in this CL
too, and a bunch of other broken tests are now fixed (introduced from
the past week of merging the CL backlog).

Change-Id: If580db1691b5b99f8ed6195070789b1f44877dd4
2018-01-01 16:03:34 -08:00
Daniel Heath 59ac14caa5 Vendor OpenSans (apache 2 licence)
Change-Id: Ie74b37efc007011b32810fd91c65b7750588a76e
2017-12-29 10:22:49 -08:00
Attila Tajti f47366c659 genfileembed: always embed paths with slashes
Also change make.go to propagate -all to genfileembed.

Fixes #982

Change-Id: I605d5fc35ae0fc9c12fca639ff0a0111836b653c
2017-12-08 09:24:14 +01:00
Paul Lindner f28eb3cce8 Remove appengine server and the old python blobserver
Change-Id: I734f4621f77ce902050e9b37805e7f8912f75e97
2017-11-30 19:13:37 -08:00
Sterchele Nicolas 2e46fca5cc Update camlistore and gopherjs to go1.9
Vendoring:
- update gopherjs to rev: b40cd48c38f9a18eb3db20d163bad78de12cf0b7
- as usual, replace the fsnotify import statements with our dummy
  pkg/misc/fakefsnotify, as described in
https://camlistore-review.googlesource.com/c/9409
- add vendor/golang.org/x/tools/go/gcimporter15 dependency from
  rev: e531a2a1c15f94033f6fa87666caeb19a688175f

- make.go + .travis.yml: make go1.9 the required version
- Update comments on doc/environments-vars.md for CAMLI_GOPHERJS_GOROOT

Fixes #948
Fixes #949

Change-Id: I9285aebadad1502708d164a9dc69e044a325cb3a
2017-09-20 08:23:11 +02:00
Paul Lindner fa46c3935d Correct various misspelled words
Change-Id: I236e880526e4c2b0bd318da041983d557e0aa885
2017-09-11 08:33:31 -07:00
Paul Jolly 4581abc238 vendor: upgrade to use myitcv.io/react
myitcv.io/react replaces github.com/myitcv/gopherjs/react.

This commits also includes relevant changes to reflect the new API of
myitcv.io/react:

https://github.com/myitcv/react/wiki/Changelog

myitcv.io/react
rev 0b147f16090bc5007116c494ca7ea95f78ee4a16

myitcv.io/gogenerate (required by myitcv.io/react/cmd/reactGen)
rev bd69a94c96953d20e106734856b69d71c8fa122b

github.com/gopherjs/jsbuiltin (required by myitcv.io/react)
rev 67703bfb044e3192fbcab025c3aeaeedafad1f2f

Change-Id: I1951519d30455915aa2f75fbb418057f8075e27c
2017-08-30 08:46:33 +01:00
mpl ccab088e61 vendor/embed/fontawesome: embed woff2 files as well
Change-Id: Idbbd099b5ee32b179d7b9c035e8477d0924bf5d9
2017-08-23 03:09:25 +02:00
mpl f1733b2162 make.go: specify GOROOT for gopherjs where needed
GOROOT needs to be specified when building gopherjs itself, and for
gopherjs, when building the go part of the web UI.

Fixes #935

Change-Id: I7f83cefa9fd44019e8f75f8a0de70e198c905fd8
2017-07-17 13:30:40 +02:00
mpl e4b7db8274 server/camlistored/ui: improve map aspect search and markers
Notably:

-do not load any markers on an empty search query, because that would
mean loading absolutely all of the items with a location, which seems
like a bad idea.

-use different markers for different nodes. For now, foursquare
checkins, file images, and files have their own marker.

-vendor in https://github.com/lvoogdt/Leaflet.awesome-markers to achieve
the above, which relies on Font Awesome, which we already have in.
icons available for the markers: http://fontawesome.io/icons/

-when no location can be inferred from the search query, set the view to
encompass all markers that were drawn.

-when a location search is known, draw a rectangle representing the
results zone.

-use thumber for image in marker popup

-use title, if possible, instead of blobRef for link text in marker
popup

-switch to directly using OpenStreetMap tiles, instead of MapBox ones.

https://storage.googleapis.com/camlistore-screenshots/Screenshot_20170622-232359.png

Change-Id: Ibc84fa988aea8b8d3a2588ee8790adf6d9b5ad7a
2017-07-06 01:03:03 +02:00
mpl 749d51281d make.go: fix building on FreeBSD
running gopherjs would fail on FreeBSD with errors such as:
../../go1/src/vendor/golang_org/x/net/route/address.go:31:35: undeclared
name: sysAF_LINK

This happens because in $GOROOT/src/vendor/golang_org/x/net/route the
needed constants are defined in zsys_freebsd_$ARCH.go files, where $ARCH
only exists for "386", "amd64", and "arm". So as gopherjs runs for the
"js" arch, all of the zsys_freebsd* files are ignored and the constants
are not defined.

This bug was reported in https://github.com/gopherjs/gopherjs/issues/511
and the "solution" eventually recommended in
https://github.com/gopherjs/gopherjs/pull/513 is to run with GOOS=linux
regardless of the host OS. Using GOOS=linux side-steps the problem since
linux does not need the problematic constants, and the GOOS value is not
supposed to matter for the generated javascript.

fixes #928

Change-Id: I20757a211ea4c671438e94e57552a0cee7a25e81
2017-05-18 01:40:19 +02:00
nico ff7cf8af05 make: fixed copy/paste by replacing *website with *camnetdns
Change-Id: Idd0fbf86dfb89f50f26f1be47f08301571b9aa7b
2017-04-18 03:18:05 +10:00
mpl 753bd38ca9 misc/docker/server: build with make.go
So far, when building camlistored docker image for CoreOS, we were not
using make.go, and we were neither running gopherjs nor embedding the
resources (but rather provide the UI resources at their default
filesystem location).

Now that we're using gopherjs for the web UI, it is a hard dependency
for the camlistore server.
We could reproduce the steps in make.go to build gopherjs, run it to
build the web ui resources, and then move the resources at the right
place, but since make.go already does the equivalent work it seems
to make more sense to use it, which is the main point of this CL.

Similarly, it seems to make more sense to now build a binary with the
resources embedded, which is the default make.go behaviour, instead of
building a "raw" camlistored, and provide the resources as additional
directories in the container image, so this CL takes that approach too.

Finally, it was necessary to add the "-static" flag to make.go, so we
can keep on building a static camlistored binary, that does not rely on
libc for DNS. Because our container image is FROM SCRATCH, with just the
necessary binaries, in order to get a container image of a reasonable
size.

One drawback of now using make.go in
misc/docker/server/build-camlistore-server.go is we're doing some
unnecessary (since we're already running in the isolation of a
container) copying to the virtual gopath, but that seems a very tiny
price to pay. Especially considering how rarely we run that code.

Change-Id: I416c86d366cd4ed2d3b8b1636a6a65a83b9f15d7
2017-04-05 02:10:12 +02:00
Steve Armstrong 9e2e35cf6f app/scanningcabinet: move static UI files to folder
Change-Id: I410fbaf0a113732cc2bde319607edab384122678
2017-03-24 21:36:03 -07:00
Mathieu Lonjaret 75424def01 Merge "pkg/server: add files "zipper" to DownloadHandler" 2017-03-17 13:36:40 +00:00