Skip to content

Commit

Permalink
Move core services logs to the journal
Browse files Browse the repository at this point in the history
Logs can now be viewed with the following, adding -f to follow
the logs.

journalctl -t default:gateway

Signed-off-by: Alex Ellis (OpenFaaS Ltd) <alexellis2@gmail.com>
  • Loading branch information
alexellis committed Sep 18, 2020
1 parent cddc10a commit faae82a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
4 changes: 2 additions & 2 deletions docker-compose.yaml
Expand Up @@ -26,8 +26,8 @@ services:
- "8222"
- "--store=memory"
- "--cluster_id=faas-cluster"
ports:
- "127.0.0.1:8222:8222"
# ports:
# - "127.0.0.1:8222:8222"

prometheus:
image: docker.io/prom/prometheus:v2.14.0
Expand Down
1 change: 0 additions & 1 deletion pkg/provider/handlers/deploy.go
Expand Up @@ -128,7 +128,6 @@ func deploy(ctx context.Context, req types.FunctionDeployment, client *container
func createTask(ctx context.Context, client *containerd.Client, container containerd.Container, cni gocni.CNI) error {

name := container.ID()
// task, taskErr := container.NewTask(ctx, cio.NewCreator(cio.WithStdio))

task, taskErr := container.NewTask(ctx, cio.BinaryIO("/usr/local/bin/faasd", nil))

Expand Down
6 changes: 3 additions & 3 deletions pkg/supervisor.go
Expand Up @@ -180,10 +180,10 @@ func (s *Supervisor) Start(svcs []Service) error {

log.Printf("Created container: %s\n", newContainer.ID())

task, err := newContainer.NewTask(ctx, cio.NewCreator(cio.WithStdio))
if err != nil {
task, taskErr := newContainer.NewTask(ctx, cio.BinaryIO("/usr/local/bin/faasd", nil))
if taskErr != nil {
log.Printf("Error creating task: %s\n", err)
return err
return taskErr
}

labels := map[string]string{}
Expand Down

0 comments on commit faae82a

Please sign in to comment.