#include <bits/stdc++.h>
using namespace std;
int n, k;
int main() {
  cin >> n >> k;
  if (n < k * 3)
    cout << -1 << '\n';
  else {
    for (int i = 1; i <= k; i++, n--) cout << i << " ";
    for (int i = 1; i <= k; i++, n -= 2) cout << i << " " << i << " ";
    for (; n; n--) cout << 1 << " ";
  }
  return 0;
}
