Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix auto_tls, and pass travis CI #24

Closed

Conversation

noelmcloughlin
Copy link
Member

This PR is attempt to fix AUTO TLS and kitchen tests.

Rationale:
Seems we need to remove unsupported ETCD_AUTO_TLS and ETCD_PEER_AUTO_TLS environment variables, and pass as --auto_tls --peer_auto_tls arguments. And etcd developers say we need
--insecure-skip-verify-tls is needed too too to get auto_tls working.

Travis CI
It this PR fixes the issue, then Travis CI kitchen tests should work.

 Sep 25 18:43:10 2fcfa892026c etcd[2860]: recognized and used environment variable ETCD_ADVERTISE_CLIENT_URLS=https://127.0.0.1:2379
Sep 25 18:43:10 2fcfa892026c etcd[2860]: recognized and used environment variable ETCD_DATA_DIR=/var/lib/etcd/etcd0
Sep 25 18:43:10 2fcfa892026c etcd[2860]: recognized and used environment variable ETCD_INITIAL_ADVERTISE_PEER_URLS=https://127.0.0.1:2380
Sep 25 18:43:10 2fcfa892026c etcd[2860]: recognized and used environment variable ETCD_INITIAL_CLUSTER=etcd0=https://127.0.0.1:2380
Sep 25 18:43:10 2fcfa892026c etcd[2860]: recognized and used environment variable ETCD_INITIAL_CLUSTER_STATE=new
Sep 25 18:43:10 2fcfa892026c etcd[2860]: recognized and used environment variable ETCD_INITIAL_CLUSTER_TOKEN=etcd-cluster-1
 Sep 25 18:43:10 2fcfa892026c etcd[2860]: recognized and used environment variable ETCD_LISTEN_CLIENT_URLS=https://127.0.0.1:2379
Sep 25 18:43:10 2fcfa892026c etcd[2860]: recognized and used environment variable ETCD_LISTEN_PEER_URLS=https://127.0.0.1:2380
 Sep 25 18:43:10 2fcfa892026c etcd[2860]: recognized and used environment variable ETCD_NAME=etcd0
Sep 25 18:43:10 2fcfa892026c etcd[2860]: unrecognized environment variable ETCD_AUTO_TLS=
Sep 25 18:43:10 2fcfa892026c etcd[2860]: unrecognized environment variable ETCD_PEER_AUTO_TLS=

@noelmcloughlin noelmcloughlin force-pushed the fix_tls branch 4 times, most recently from c1d8ec6 to cd9fadf Compare September 25, 2018 21:00
@noelmcloughlin
Copy link
Member Author

Tested successfully on suse. hopefully travis passes

[Service]
User=root
Type=notify

Environment='ETCD_ADVERTISE_CLIENT_URLS=https://127.0.0.1:2379'
Environment='ETCD_DATA_DIR=/var/lib/etcd/etcd0'
Environment='ETCD_INITIAL_ADVERTISE_PEER_URLS=https://127.0.0.1:2380'
Environment='ETCD_INITIAL_CLUSTER=etcd0=https://127.0.0.1:2380'
Environment='ETCD_INITIAL_CLUSTER_STATE=new'
Environment='ETCD_INITIAL_CLUSTER_TOKEN=etcd-cluster-1'
Environment='ETCD_LISTEN_CLIENT_URLS=https://127.0.0.1:2379'
Environment='ETCD_LISTEN_PEER_URLS=https://127.0.0.1:2380'
Environment='ETCD_NAME=etcd0'
Environment='ETCDCTL_API=3'
Environment='ETCDCTL_BACKUP_DIR='
Environment='ETCDCTL_CA_FILE='
Environment='ETCDCTL_CERT_FILE='
Environment='ETCDCTL_DATA_DIR='
Environment='ETCDCTL_DISCOVERY_SRV='
Environment='ETCDCTL_ENDPOINT=https://127.0.0.1:2379'
Environment='ETCDCTL_KEY_FILE='
Environment='ETCDCTL_PEERS=https://127.0.0.1:2379'
Environment='ETCDCTL_USERNAME='

ExecStart=/usr/local/coreos/etcd-v3.2.18-linux-amd64/etcd --auto-tls  --peer-auto-tls 
Restart=always
RestartSec=10s
LimitNOFILE=40000
WorkingDirectory=/var/lib/etcd/

[Install]
WantedBy=multi-user.target

---

       ID: etcd-systemd
    Function: module.run
        Name: service.systemctl_reload
      Result: True
     Comment: Module function service.systemctl_reload executed
     Started: 22:49:41.505269
    Duration: 567.384 ms
     Changes:   
              ----------
              ret:
                  True
----------
          ID: etcd_etcd_running
    Function: service.running
        Name: etcd
      Result: True
     Comment: The service etcd is already running
     Started: 22:49:44.216618
    Duration: 188.626 ms
     Changes:   
----------
          ID: etcd_whats_wrong_with_etcd
    Function: cmd.run
        Name: journalctl -xe -u etcd
      Result: True
     Comment: State was not run because onfail req did not change
     Changes:   

@noelmcloughlin noelmcloughlin deleted the fix_tls branch January 27, 2019 19:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant