Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Feb 24, 2020. It is now read-only.
This repository was archived by the owner on Feb 24, 2020. It is now read-only.

Error marshaling configuration from the website #3916

@ogham

Description

@ogham

Environment

rkt Version: 1.29.0
appc Version: 0.8.11
Go Version: go1.8.3
Go OS/Arch: linux/amd64
Features: -TPM +SDJOURNAL
--
Linux 4.4.0-116-generic x86_64
--
NAME="Ubuntu"
VERSION="16.04.4 LTS (Xenial Xerus)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 16.04.4 LTS"
VERSION_ID="16.04"
HOME_URL="http://www.ubuntu.com/"
SUPPORT_URL="http://help.ubuntu.com/"
BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/"
VERSION_CODENAME=xenial
UBUNTU_CODENAME=xenial
--
systemd 229
+PAM +AUDIT +SELINUX +IMA +APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ -LZ4 +SECCOMP +BLKID +ELFUTILS +KMOD -IDN

What did you do?

I ran rkt config with a sample configuration file I copied from the website.

What did you expect to see?

A description of my config from rkt config.

What did you see instead?

A stacktrace:

vagrant@vm:/vagrant/jobs$ sudo cat /usr/lib/rkt/auth.d/s3.json
{
  "rktKind": "auth",
  "rktVersion": "v1",
  "domains": ["my-s3-bucket.s3.amazonaws.com"],
  "type": "aws",
  "credentials": {
    "accessKeyID": "foo",
    "secretAccessKey": "bar",
    "awsRegion": "us-east-1"
  }
}
vagrant@vm:/vagrant/jobs$ sudo rkt config
config: error marshaling configuration: json: error calling MarshalJSON for type *config.Config: unknown headerer type
panic: error marshaling configuration: json: error calling MarshalJSON for type *config.Config: unknown headerer type

goroutine 1 [running, locked to thread]:
log.(*Logger).Panic(0xc4203c2aa0, 0xc42026bc20, 0x1, 0x1)
  /usr/lib/go-1.8/src/log/log.go:208 +0xbe
github.com/rkt/rkt/pkg/log.(*Logger).PanicE(0xc4203da6d0, 0xd10aa8, 0x1e, 0x12c7180, 0xc4203ada80)
  /opt/build-rkt/gopath/src/github.com/rkt/rkt/pkg/log/log.go:133 +0xdf
main.runConfig(0x12b9ac0, 0x1341aa8, 0x0, 0x0, 0x0)
  /opt/build-rkt/gopath/src/github.com/rkt/rkt/rkt/config.go:53 +0x1c1
main.runWrapper.func1(0x12b9ac0, 0x1341aa8, 0x0, 0x0)
  /opt/build-rkt/gopath/src/github.com/rkt/rkt/rkt/rkt.go:186 +0xa2
github.com/rkt/rkt/vendor/github.com/spf13/cobra.(*Command).execute(0x12b9ac0, 0x1341aa8, 0x0, 0x0, 0x12b9ac0, 0x1341aa8)
  /opt/build-rkt/gopath/src/github.com/rkt/rkt/vendor/github.com/spf13/cobra/command.go:565 +0x203
github.com/rkt/rkt/vendor/github.com/spf13/cobra.(*Command).ExecuteC(0x12b7ec0, 0xcfa67d, 0x0, 0x0)
  /opt/build-rkt/gopath/src/github.com/rkt/rkt/vendor/github.com/spf13/cobra/command.go:651 +0x339
github.com/rkt/rkt/vendor/github.com/spf13/cobra.(*Command).Execute(0x12b7ec0, 0xc4200001a0, 0xc4200001a0)
  /opt/build-rkt/gopath/src/github.com/rkt/rkt/vendor/github.com/spf13/cobra/command.go:610 +0x2b
main.main()
  /opt/build-rkt/gopath/src/github.com/rkt/rkt/rkt/main.go:32 +0x93

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions