Merge pull request #143 from darkspot-org/develop

Release 1.0.0-rc2
main
Aloïs Micard 3 years ago committed by GitHub
commit 48dd659050
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -51,41 +51,41 @@ dockers:
- goos: linux
goarch: amd64
image_templates:
- "creekorful/bs-blacklister:latest"
- "creekorful/bs-blacklister:{{ replace .Tag \"v\" \"\" }}"
- "creekorful/bs-blacklister:{{ .Major }}"
- "darkspot/bs-blacklister:latest"
- "darkspot/bs-blacklister:{{ replace .Tag \"v\" \"\" }}"
- "darkspot/bs-blacklister:{{ .Major }}"
skip_push: false
dockerfile: build/docker/Dockerfile.blacklister
- goos: linux
goarch: amd64
image_templates:
- "creekorful/bs-configapi:latest"
- "creekorful/bs-configapi:{{ replace .Tag \"v\" \"\" }}"
- "creekorful/bs-configapi:{{ .Major }}"
- "darkspot/bs-configapi:latest"
- "darkspot/bs-configapi:{{ replace .Tag \"v\" \"\" }}"
- "darkspot/bs-configapi:{{ .Major }}"
skip_push: false
dockerfile: build/docker/Dockerfile.configapi
- goos: linux
goarch: amd64
image_templates:
- "creekorful/bs-crawler:latest"
- "creekorful/bs-crawler:{{ replace .Tag \"v\" \"\" }}"
- "creekorful/bs-crawler:{{ .Major }}"
- "darkspot/bs-crawler:latest"
- "darkspot/bs-crawler:{{ replace .Tag \"v\" \"\" }}"
- "darkspot/bs-crawler:{{ .Major }}"
skip_push: false
dockerfile: build/docker/Dockerfile.crawler
- goos: linux
goarch: amd64
image_templates:
- "creekorful/bs-indexer:latest"
- "creekorful/bs-indexer:{{ replace .Tag \"v\" \"\" }}"
- "creekorful/bs-indexer:{{ .Major }}"
- "darkspot/bs-indexer:latest"
- "darkspot/bs-indexer:{{ replace .Tag \"v\" \"\" }}"
- "darkspot/bs-indexer:{{ .Major }}"
skip_push: false
dockerfile: build/docker/Dockerfile.indexer
- goos: linux
goarch: amd64
image_templates:
- "creekorful/bs-scheduler:latest"
- "creekorful/bs-scheduler:{{ replace .Tag \"v\" \"\" }}"
- "creekorful/bs-scheduler:{{ .Major }}"
- "darkspot/bs-scheduler:latest"
- "darkspot/bs-scheduler:{{ replace .Tag \"v\" \"\" }}"
- "darkspot/bs-scheduler:{{ .Major }}"
skip_push: false
dockerfile: build/docker/Dockerfile.scheduler
checksum:

@ -7,10 +7,22 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [Unreleased]
## [1.0.0-rc2] - 2021-01-13
### Added
- Added kubernetes definition files.
### Changed
- Migrate the repository & images to new organization.
## [1.0.0-rc1] - 2021-01-12
Initial stable release candidate.
[unreleased]: https://github.com/creekorful/bathyscaphe/compare/v1.0.0-rc1...HEAD
[Unreleased]: https://github.com/darkspot-org/bathyscaphe/compare/v1.0.0-rc2...HEAD
[1.0.0-rc2]: https://github.com/olivierlacan/keep-a-changelog/compare/v1.0.0-rc1...v1.0.0-rc2
[v1.0.0-rc1]: https://github.com/creekorful/bathyscaphe/releases/tag/v1.0.0-rc1
[1.0.0-rc1]: https://github.com/darkspot-org/bathyscaphe/releases/tag/v1.0.0-rc1

@ -1,6 +1,6 @@
# Bathyscaphe dark web crawler
![CI](https://github.com/creekorful/bathyscaphe/workflows/CI/badge.svg)
![CI](https://github.com/darkspot-org/bathyscaphe/workflows/CI/badge.svg)
Bathyscaphe is a Go written, fast, highly configurable, cloud-native dark web crawler.
@ -9,7 +9,7 @@ Bathyscaphe is a Go written, fast, highly configurable, cloud-native dark web cr
To start the crawler, one just need to execute the following command:
```sh
$ ./scripts/start.sh
$ ./scripts/docker/start.sh
```
and wait for all containers to start.
@ -21,7 +21,7 @@ and wait for all containers to start.
# How to initiate crawling
One can use the RabbitMQ dashhboard available at localhost:15003, and publish a new JSON object in the **crawlingQueue**
One can use the RabbitMQ dashboard available at localhost:15003, and publish a new JSON object in the **crawlingQueue**
.
The object should look like this:
@ -38,7 +38,7 @@ If one want to speed up the crawling, he can scale the instance of crawling comp
This may be done by issuing the following command after the crawler is started:
```sh
$ ./scripts/scale.sh crawler=5
$ ./scripts/docker/start.sh -d --scale crawler=5
```
this will set the number of crawler instance to 5.

@ -1,8 +1,8 @@
package main
import (
"github.com/creekorful/bathyscaphe/internal/blacklister"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/blacklister"
"github.com/darkspot-org/bathyscaphe/internal/process"
"os"
)

@ -1,8 +1,8 @@
package main
import (
"github.com/creekorful/bathyscaphe/internal/configapi"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/configapi"
"github.com/darkspot-org/bathyscaphe/internal/process"
"os"
)

@ -1,8 +1,8 @@
package main
import (
"github.com/creekorful/bathyscaphe/internal/crawler"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/crawler"
"github.com/darkspot-org/bathyscaphe/internal/process"
"os"
)

@ -1,8 +1,8 @@
package main
import (
"github.com/creekorful/bathyscaphe/internal/indexer"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/indexer"
"github.com/darkspot-org/bathyscaphe/internal/process"
"os"
)

@ -1,8 +1,8 @@
package main
import (
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/creekorful/bathyscaphe/internal/scheduler"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/scheduler"
"os"
)

@ -29,7 +29,7 @@ services:
volumes:
- redisdata:/data
crawler:
image: creekorful/bs-crawler:latest
image: darkspot/bs-crawler:latest
command: >
--log-level debug
--event-srv amqp://guest:guest@rabbitmq:5672
@ -41,7 +41,7 @@ services:
- torproxy
- configapi
scheduler:
image: creekorful/bs-scheduler:latest
image: darkspot/bs-scheduler:latest
command: >
--log-level debug
--event-srv amqp://guest:guest@rabbitmq:5672
@ -54,7 +54,7 @@ services:
- configapi
- redis
indexer-local:
image: creekorful/bs-indexer:latest
image: darkspot/bs-indexer:latest
command: >
--log-level debug
--event-srv amqp://guest:guest@rabbitmq:5672
@ -68,7 +68,7 @@ services:
- rabbitmq
- configapi
indexer-es:
image: creekorful/bs-indexer:latest
image: darkspot/bs-indexer:latest
command: >
--log-level debug
--event-srv amqp://guest:guest@rabbitmq:5672
@ -82,7 +82,7 @@ services:
- elasticsearch
- configapi
configapi:
image: creekorful/bs-configapi:latest
image: darkspot/bs-configapi:latest
command: >
--log-level debug
--event-srv amqp://guest:guest@rabbitmq:5672
@ -98,7 +98,7 @@ services:
ports:
- 15006:8080
blacklister:
image: creekorful/bs-blacklister:latest
image: darkspot/bs-blacklister:latest
command: >
--log-level debug
--event-srv amqp://guest:guest@rabbitmq:5672

@ -0,0 +1,30 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: blacklister-deployment
labels:
app: blacklister
spec:
replicas: 5
selector:
matchLabels:
app: blacklister
template:
metadata:
labels:
app: blacklister
spec:
containers:
- name: blacklister
image: darkspot/bs-blacklister:latest
args:
- --log-level
- debug
- --event-srv
- amqp://bathyscaphe:nHEsR9MpJfxLwwkKP48mhMtGFTBqMTfC@rabbitmq:5672
- --config-api
- http://configapi-service
- --cache-srv
- redis://default:WtVcUp9yebNnwjuE2LuumJM52AJ9sZ@redis-master:6379
- --tor-proxy
- torproxy-service:9050

@ -0,0 +1,47 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: configapi-deployment
labels:
app: configapi
spec:
replicas: 1
selector:
matchLabels:
app: configapi
template:
metadata:
labels:
app: configapi
spec:
containers:
- name: configapi
image: darkspot/bs-configapi:latest
args:
- --log-level
- debug
- --event-srv
- amqp://bathyscaphe:nHEsR9MpJfxLwwkKP48mhMtGFTBqMTfC@rabbitmq:5672
- --cache-srv
- redis://default:WtVcUp9yebNnwjuE2LuumJM52AJ9sZ@redis-master:6379
- --default-value
- forbidden-hostnames=[]
- --default-value
- allowed-mime-types=[{"content-type":"text","extensions":["html","php","aspx", "htm"]}]
- --default-value
- refresh-delay={"delay":0}
- --default-value
- blacklist-config={"threshold":5, "ttl":1200}
---
apiVersion: v1
kind: Service
metadata:
name: configapi-service
spec:
selector:
app: configapi
ports:
- protocol: TCP
port: 80
targetPort: 8080

@ -0,0 +1,28 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: crawler-deployment
labels:
app: crawler
spec:
replicas: 20
selector:
matchLabels:
app: crawler
template:
metadata:
labels:
app: crawler
spec:
containers:
- name: crawler
image: darkspot/bs-crawler:latest
args:
- --log-level
- debug
- --event-srv
- amqp://bathyscaphe:nHEsR9MpJfxLwwkKP48mhMtGFTBqMTfC@rabbitmq:5672
- --tor-proxy
- torproxy-service:9050
- --config-api
- http://configapi-service

@ -0,0 +1,2 @@
# Config file to switch to single node
replicas: 1

@ -0,0 +1,3 @@
auth:
username: bathyscaphe
password: nHEsR9MpJfxLwwkKP48mhMtGFTBqMTfC

@ -0,0 +1 @@
password: WtVcUp9yebNnwjuE2LuumJM52AJ9sZ

@ -0,0 +1,32 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: indexer-es-deployment
labels:
app: indexer-es
spec:
replicas: 2
selector:
matchLabels:
app: indexer-es
template:
metadata:
labels:
app: indexer-es
spec:
containers:
- name: indexer
image: darkspot/bs-indexer:latest
args:
- --log-level
- debug
- --event-srv
- amqp://bathyscaphe:nHEsR9MpJfxLwwkKP48mhMtGFTBqMTfC@rabbitmq:5672
- --event-prefetch
- '20'
- --config-api
- http://configapi-service
- --index-driver
- elastic
- --index-dest
- http://elasticsearch-master:9200

@ -0,0 +1,30 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: scheduler-deployment
labels:
app: scheduler
spec:
replicas: 2
selector:
matchLabels:
app: scheduler
template:
metadata:
labels:
app: scheduler
spec:
containers:
- name: scheduler
image: darkspot/bs-scheduler:latest
args:
- --log-level
- debug
- --event-srv
- amqp://bathyscaphe:nHEsR9MpJfxLwwkKP48mhMtGFTBqMTfC@rabbitmq:5672
- --event-prefetch
- '20'
- --config-api
- http://configapi-service
- --cache-srv
- redis://default:WtVcUp9yebNnwjuE2LuumJM52AJ9sZ@redis-master:6379

@ -0,0 +1,30 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: torproxy-deployment
labels:
app: torproxy
spec:
replicas: 3
selector:
matchLabels:
app: torproxy
template:
metadata:
labels:
app: torproxy
spec:
containers:
- name: torproxy
image: dperson/torproxy:latest
---
apiVersion: v1
kind: Service
metadata:
name: torproxy-service
spec:
selector:
app: torproxy
ports:
- protocol: TCP
port: 9050

@ -1,4 +1,4 @@
module github.com/creekorful/bathyscaphe
module github.com/darkspot-org/bathyscaphe
go 1.14

@ -2,11 +2,11 @@ package blacklister
import (
"fmt"
"github.com/creekorful/bathyscaphe/internal/cache"
configapi "github.com/creekorful/bathyscaphe/internal/configapi/client"
"github.com/creekorful/bathyscaphe/internal/event"
chttp "github.com/creekorful/bathyscaphe/internal/http"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/cache"
configapi "github.com/darkspot-org/bathyscaphe/internal/configapi/client"
"github.com/darkspot-org/bathyscaphe/internal/event"
chttp "github.com/darkspot-org/bathyscaphe/internal/http"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/rs/zerolog/log"
"github.com/urfave/cli/v2"
"net/http"

@ -2,16 +2,16 @@ package blacklister
import (
"errors"
"github.com/creekorful/bathyscaphe/internal/cache_mock"
configapi "github.com/creekorful/bathyscaphe/internal/configapi/client"
"github.com/creekorful/bathyscaphe/internal/configapi/client_mock"
"github.com/creekorful/bathyscaphe/internal/event"
"github.com/creekorful/bathyscaphe/internal/event_mock"
"github.com/creekorful/bathyscaphe/internal/http"
"github.com/creekorful/bathyscaphe/internal/http_mock"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/creekorful/bathyscaphe/internal/process_mock"
"github.com/creekorful/bathyscaphe/internal/test"
"github.com/darkspot-org/bathyscaphe/internal/cache_mock"
configapi "github.com/darkspot-org/bathyscaphe/internal/configapi/client"
"github.com/darkspot-org/bathyscaphe/internal/configapi/client_mock"
"github.com/darkspot-org/bathyscaphe/internal/event"
"github.com/darkspot-org/bathyscaphe/internal/event_mock"
"github.com/darkspot-org/bathyscaphe/internal/http"
"github.com/darkspot-org/bathyscaphe/internal/http_mock"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/process_mock"
"github.com/darkspot-org/bathyscaphe/internal/test"
"github.com/golang/mock/gomock"
"testing"
"time"

@ -6,7 +6,7 @@ import (
"bytes"
"encoding/json"
"fmt"
"github.com/creekorful/bathyscaphe/internal/event"
"github.com/darkspot-org/bathyscaphe/internal/event"
"github.com/rs/zerolog/log"
"io/ioutil"
"net/http"

@ -1,8 +1,8 @@
package client
import (
"github.com/creekorful/bathyscaphe/internal/event"
"github.com/creekorful/bathyscaphe/internal/event_mock"
"github.com/darkspot-org/bathyscaphe/internal/event"
"github.com/darkspot-org/bathyscaphe/internal/event_mock"
"github.com/golang/mock/gomock"
"sync"
"testing"

@ -2,9 +2,9 @@ package configapi
import (
"fmt"
"github.com/creekorful/bathyscaphe/internal/cache"
"github.com/creekorful/bathyscaphe/internal/event"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/cache"
"github.com/darkspot-org/bathyscaphe/internal/event"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/gorilla/mux"
"github.com/rs/zerolog/log"
"github.com/urfave/cli/v2"

@ -1,13 +1,13 @@
package configapi
import (
"github.com/creekorful/bathyscaphe/internal/cache"
"github.com/creekorful/bathyscaphe/internal/cache_mock"
"github.com/creekorful/bathyscaphe/internal/event"
"github.com/creekorful/bathyscaphe/internal/event_mock"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/creekorful/bathyscaphe/internal/process_mock"
"github.com/creekorful/bathyscaphe/internal/test"
"github.com/darkspot-org/bathyscaphe/internal/cache"
"github.com/darkspot-org/bathyscaphe/internal/cache_mock"
"github.com/darkspot-org/bathyscaphe/internal/event"
"github.com/darkspot-org/bathyscaphe/internal/event_mock"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/process_mock"
"github.com/darkspot-org/bathyscaphe/internal/test"
"github.com/golang/mock/gomock"
"github.com/gorilla/mux"
"io/ioutil"

@ -1,7 +1,7 @@
package constraint
import (
configapi "github.com/creekorful/bathyscaphe/internal/configapi/client"
configapi "github.com/darkspot-org/bathyscaphe/internal/configapi/client"
"net/url"
"strings"
)

@ -1,8 +1,8 @@
package constraint
import (
"github.com/creekorful/bathyscaphe/internal/configapi/client"
"github.com/creekorful/bathyscaphe/internal/configapi/client_mock"
"github.com/darkspot-org/bathyscaphe/internal/configapi/client"
"github.com/darkspot-org/bathyscaphe/internal/configapi/client_mock"
"github.com/golang/mock/gomock"
"testing"
)

@ -2,12 +2,12 @@ package crawler
import (
"fmt"
"github.com/creekorful/bathyscaphe/internal/clock"
configapi "github.com/creekorful/bathyscaphe/internal/configapi/client"
"github.com/creekorful/bathyscaphe/internal/constraint"
"github.com/creekorful/bathyscaphe/internal/event"
chttp "github.com/creekorful/bathyscaphe/internal/http"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/clock"
configapi "github.com/darkspot-org/bathyscaphe/internal/configapi/client"
"github.com/darkspot-org/bathyscaphe/internal/constraint"
"github.com/darkspot-org/bathyscaphe/internal/event"
chttp "github.com/darkspot-org/bathyscaphe/internal/http"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/rs/zerolog/log"
"github.com/urfave/cli/v2"
"io/ioutil"

@ -2,16 +2,16 @@ package crawler
import (
"errors"
"github.com/creekorful/bathyscaphe/internal/clock_mock"
"github.com/creekorful/bathyscaphe/internal/configapi/client"
"github.com/creekorful/bathyscaphe/internal/configapi/client_mock"
"github.com/creekorful/bathyscaphe/internal/event"
"github.com/creekorful/bathyscaphe/internal/event_mock"
"github.com/creekorful/bathyscaphe/internal/http"
"github.com/creekorful/bathyscaphe/internal/http_mock"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/creekorful/bathyscaphe/internal/process_mock"
"github.com/creekorful/bathyscaphe/internal/test"
"github.com/darkspot-org/bathyscaphe/internal/clock_mock"
"github.com/darkspot-org/bathyscaphe/internal/configapi/client"
"github.com/darkspot-org/bathyscaphe/internal/configapi/client_mock"
"github.com/darkspot-org/bathyscaphe/internal/event"
"github.com/darkspot-org/bathyscaphe/internal/event_mock"
"github.com/darkspot-org/bathyscaphe/internal/http"
"github.com/darkspot-org/bathyscaphe/internal/http_mock"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/process_mock"
"github.com/darkspot-org/bathyscaphe/internal/test"
"github.com/golang/mock/gomock"
"strings"
"testing"

@ -1,7 +1,7 @@
package index
import (
"github.com/creekorful/bathyscaphe/internal/event"
"github.com/darkspot-org/bathyscaphe/internal/event"
"testing"
"time"
)

@ -2,11 +2,11 @@ package indexer
import (
"fmt"
configapi "github.com/creekorful/bathyscaphe/internal/configapi/client"
"github.com/creekorful/bathyscaphe/internal/constraint"
"github.com/creekorful/bathyscaphe/internal/event"
"github.com/creekorful/bathyscaphe/internal/indexer/index"
"github.com/creekorful/bathyscaphe/internal/process"
configapi "github.com/darkspot-org/bathyscaphe/internal/configapi/client"
"github.com/darkspot-org/bathyscaphe/internal/constraint"
"github.com/darkspot-org/bathyscaphe/internal/event"
"github.com/darkspot-org/bathyscaphe/internal/indexer/index"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/rs/zerolog/log"
"github.com/urfave/cli/v2"
"net/http"

@ -2,15 +2,15 @@ package indexer
import (
"errors"
"github.com/creekorful/bathyscaphe/internal/configapi/client"
"github.com/creekorful/bathyscaphe/internal/configapi/client_mock"
"github.com/creekorful/bathyscaphe/internal/event"
"github.com/creekorful/bathyscaphe/internal/event_mock"
"github.com/creekorful/bathyscaphe/internal/indexer/index"
"github.com/creekorful/bathyscaphe/internal/indexer/index_mock"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/creekorful/bathyscaphe/internal/process_mock"
"github.com/creekorful/bathyscaphe/internal/test"
"github.com/darkspot-org/bathyscaphe/internal/configapi/client"
"github.com/darkspot-org/bathyscaphe/internal/configapi/client_mock"
"github.com/darkspot-org/bathyscaphe/internal/event"
"github.com/darkspot-org/bathyscaphe/internal/event_mock"
"github.com/darkspot-org/bathyscaphe/internal/indexer/index"
"github.com/darkspot-org/bathyscaphe/internal/indexer/index_mock"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/process_mock"
"github.com/darkspot-org/bathyscaphe/internal/test"
"github.com/golang/mock/gomock"
"reflect"
"testing"

@ -6,11 +6,11 @@ import (
"context"
"crypto/tls"
"fmt"
"github.com/creekorful/bathyscaphe/internal/cache"
"github.com/creekorful/bathyscaphe/internal/clock"
configapi "github.com/creekorful/bathyscaphe/internal/configapi/client"
"github.com/creekorful/bathyscaphe/internal/event"
chttp "github.com/creekorful/bathyscaphe/internal/http"
"github.com/darkspot-org/bathyscaphe/internal/cache"
"github.com/darkspot-org/bathyscaphe/internal/clock"
configapi "github.com/darkspot-org/bathyscaphe/internal/configapi/client"
"github.com/darkspot-org/bathyscaphe/internal/event"
chttp "github.com/darkspot-org/bathyscaphe/internal/http"
"github.com/rs/zerolog"
"github.com/rs/zerolog/log"
"github.com/urfave/cli/v2"
@ -27,7 +27,7 @@ import (
type Feature int
const (
version = "1.0.0-rc1"
version = "1.0.0-rc2"
// EventFeature is the feature to plug the process to the event server
EventFeature Feature = iota

@ -4,11 +4,11 @@ import (
"errors"
"fmt"
"github.com/PuerkitoBio/purell"
"github.com/creekorful/bathyscaphe/internal/cache"
configapi "github.com/creekorful/bathyscaphe/internal/configapi/client"
"github.com/creekorful/bathyscaphe/internal/constraint"
"github.com/creekorful/bathyscaphe/internal/event"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/cache"
configapi "github.com/darkspot-org/bathyscaphe/internal/configapi/client"
"github.com/darkspot-org/bathyscaphe/internal/constraint"
"github.com/darkspot-org/bathyscaphe/internal/event"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/rs/zerolog/log"
"github.com/urfave/cli/v2"
"hash/fnv"
@ -104,7 +104,7 @@ func (state *State) handleNewResourceEvent(subscriber event.Subscriber, msg even
}
// We are working using URL hash to reduce memory consumption.
// See: https://github.com/creekorful/bathyscaphe/issues/130
// See: https://github.com/darkspot-org/bathyscaphe/issues/130
var urlHashes []string
for _, u := range urls {
c := fnv.New64()

@ -2,15 +2,15 @@ package scheduler
import (
"errors"
"github.com/creekorful/bathyscaphe/internal/cache"
"github.com/creekorful/bathyscaphe/internal/cache_mock"
"github.com/creekorful/bathyscaphe/internal/configapi/client"
"github.com/creekorful/bathyscaphe/internal/configapi/client_mock"
"github.com/creekorful/bathyscaphe/internal/event"
"github.com/creekorful/bathyscaphe/internal/event_mock"
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/creekorful/bathyscaphe/internal/process_mock"
"github.com/creekorful/bathyscaphe/internal/test"
"github.com/darkspot-org/bathyscaphe/internal/cache"
"github.com/darkspot-org/bathyscaphe/internal/cache_mock"
"github.com/darkspot-org/bathyscaphe/internal/configapi/client"
"github.com/darkspot-org/bathyscaphe/internal/configapi/client_mock"
"github.com/darkspot-org/bathyscaphe/internal/event"
"github.com/darkspot-org/bathyscaphe/internal/event_mock"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/process_mock"
"github.com/darkspot-org/bathyscaphe/internal/test"
"github.com/golang/mock/gomock"
"hash/fnv"
"strconv"

@ -1,8 +1,8 @@
package test
import (
"github.com/creekorful/bathyscaphe/internal/process"
"github.com/creekorful/bathyscaphe/internal/process_mock"
"github.com/darkspot-org/bathyscaphe/internal/process"
"github.com/darkspot-org/bathyscaphe/internal/process_mock"
"github.com/golang/mock/gomock"
"reflect"
"testing"

@ -1,3 +0,0 @@
#!/bin/bash
./scripts/exec.sh down "$@"

@ -0,0 +1,3 @@
#!/bin/bash
./scripts/docker/exec.sh down "$@"

@ -0,0 +1,3 @@
#!/bin/bash
./scripts/docker/exec.sh logs "$@"

@ -0,0 +1,3 @@
#!/bin/bash
./scripts/docker/exec.sh ps "$@"

@ -0,0 +1,3 @@
#!/bin/bash
./scripts/docker/exec.sh up "$@"

@ -0,0 +1,3 @@
#!/bin/bash
./scripts/docker/exec.sh stop "$@"

@ -46,11 +46,11 @@ print("there is {} forbidden hostnames defined in ConfigAPI".format(len(forbidde
# Merge the lists while preventing duplicates
for forbidden_hostname in forbidden_hostnames:
add_if_not_exist(new_hostnames, forbidden_hostname['hostname'])
print("there is {} forbidden hostnames now".format(len(forbidden_hostnames)))
print("there is {} forbidden hostnames now".format(len(new_hostnames)))
# Update ConfigAPI
headers = {'Content-Type': 'application/json', 'Accept': 'application/json'}
r = requests.put(config_api_uri + "/config/forbidden-hostnames", json.dumps(forbidden_hostnames), headers=headers)
r = requests.put(config_api_uri + "/config/forbidden-hostnames", json.dumps(new_hostnames), headers=headers)
if r.ok:
print("successfully updated forbidden hostnames")

@ -0,0 +1,19 @@
#!/bin/bash
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo add elastic https://helm.elastic.co
kubectl create namespace bathyscaphe
helm install --namespace bathyscaphe redis -f deployments/k8s/helm/redis-values.yaml bitnami/redis
helm install --namespace bathyscaphe rabbitmq -f deployments/k8s/helm/rabbitmq-values.yaml bitnami/rabbitmq
helm install --namespace bathyscaphe elasticsearch elastic/elasticsearch
helm install --namespace bathyscaphe kibana elastic/kibana
# Install our resources
kubectl -n bathyscaphe apply -f deployments/k8s/torproxy.yaml
kubectl -n bathyscaphe apply -f deployments/k8s/configapi.yaml
kubectl -n bathyscaphe apply -f deployments/k8s/crawler.yaml
kubectl -n bathyscaphe apply -f deployments/k8s/scheduler.yaml
kubectl -n bathyscaphe apply -f deployments/k8s/blacklister.yaml
kubectl -n bathyscaphe apply -f deployments/k8s/indexer-es.yaml

@ -1,3 +0,0 @@
#!/bin/bash
./scripts/exec.sh logs "$@"

@ -1,3 +0,0 @@
#!/bin/bash
./scripts/exec.sh ps "$@"

@ -1,3 +0,0 @@
#!/bin/bash
./scripts/exec.sh scale "$@"

@ -1,3 +0,0 @@
#!/bin/bash
./scripts/exec.sh up "$@"

@ -1,3 +0,0 @@
#!/bin/bash
./scripts/exec.sh stop "$@"
Loading…
Cancel
Save