#include <bits/stdc++.h>
using namespace std;
const int MOD = 1e9 + 7;
int n, k;
int main() {
  scanf("%d %d", &n, &k);
  if (3 * k > n) {
    printf("-1\n");
    return 0;
  }
  int j = 0;
  for (int i = 1; i <= k; i++, j += 2) printf("%d %d ", i, i);
  for (int i = 1; i <= k; i++, j++) printf("%d ", i);
  for (; j < n; j++) printf("%d ", 1);
  printf("\n");
  return 0;
}
