Slice okra lengthwise. Heat oil in a skillet over medium heat. Add onions and salt and cook until translucent (about 5 minutes). Add garlic and cook for 1 minute more. Reduce heat to medium low and add ginger, pepper, cardamom and okra. Cook uncovered for 20 minutes. Season with salt and pepper and serve alongside rice.